Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
ld
go-ld-prime
Commits
3fde1f4c
Commit
3fde1f4c
authored
Jul 15, 2019
by
Eric Myhre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Correctly represent schema.StructRepresentation.
parent
dc442aca
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
2 deletions
+20
-2
schema/type.go
schema/type.go
+20
-2
No files found.
schema/type.go
View file @
3fde1f4c
...
@@ -151,8 +151,11 @@ var (
...
@@ -151,8 +151,11 @@ var (
type
TypeStruct
struct
{
type
TypeStruct
struct
{
anyType
anyType
tupleStyle
bool
// if true, ReprKind=Array instead of map (and optional fields are invalid!)
// n.b. `Fields` is an (order-preserving!) map in the schema-schema;
fields
[]
StructField
// but it's a list here, with the keys denormalized into the value,
// because that's typically how we use it.
fields
[]
StructField
representation
StructRepresentation
}
}
type
StructField
struct
{
type
StructField
struct
{
name
string
name
string
...
@@ -161,6 +164,21 @@ type StructField struct {
...
@@ -161,6 +164,21 @@ type StructField struct {
nullable
bool
nullable
bool
}
}
type
StructRepresentation
interface
{
_StructRepresentation
()
}
func
(
StructRepresentation_Map
)
_StructRepresentation
()
{}
func
(
StructRepresentation_Tuple
)
_StructRepresentation
()
{}
func
(
StructRepresentation_StringPairs
)
_StructRepresentation
()
{}
func
(
StructRepresentation_StringJoin
)
_StructRepresentation
()
{}
type
StructRepresentation_Map
struct
{
renames
map
[
string
]
string
implicits
map
[
string
]
interface
{}
}
type
StructRepresentation_Tuple
struct
{}
type
StructRepresentation_StringPairs
struct
{
sep1
,
sep2
string
}
type
StructRepresentation_StringJoin
struct
{
sep
string
}
type
TypeEnum
struct
{
type
TypeEnum
struct
{
anyType
anyType
members
[]
string
members
[]
string
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment