Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/crestonbunch/godata
/ functions
Functions
141 in github.com/crestonbunch/godata
⨍
Functions
141
◇
Types & classes
74
↓ 111 callers
Method
Error
()
errors.go:8
↓ 51 callers
Method
DefineOperator
Add an operator to the language. Provide the token, a precedence, and whether the operator is left, right, or not associative.
parser.go:122
↓ 45 callers
Method
DefineFunction
Add a function to the language
parser.go:127
↓ 37 callers
Method
ExposePrimitive
Expose an OData primitive property on an entity. You must provide a corresponding table column in the database.
providers/mysql.go:319
↓ 32 callers
Function
BadRequestError
(message string)
errors.go:12
↓ 31 callers
Method
Add
(pattern string, token int)
parser.go:39
↓ 15 callers
Method
ExposeEntity
Expose a table in the MySQL database as an entity with the given name in the OData service.
providers/mysql.go:235
↓ 15 callers
Method
ExposeEntitySet
Expose a queryable collection of entities
providers/mysql.go:243
↓ 15 callers
Method
ExposeKey
Expose a key on an entity returned by MySQLGoDataProvider.ExposeEntity. This is a necessary step for every entity. You must provide a column in the da
providers/mysql.go:311
↓ 14 callers
Method
Empty
()
parser.go:276
↓ 13 callers
Method
Enqueue
(t *Token)
parser.go:301
↓ 13 callers
Method
Tokenize
(target string)
parser.go:83
↓ 12 callers
Method
BindProperty
Adds a NavigationPropertyBinding to two entity sets that are mapped together by a relationship. This SHOULD be done for any entity sets for whom their
providers/mysql.go:300
↓ 12 callers
Method
Get
Return the first key in the map. This is how you should get the identifier for single values, e.g. when the path is Employee(1), etc.
request_model.go:127
↓ 12 callers
Function
NotImplementedError
(message string)
errors.go:36
↓ 11 callers
Method
InfixToPostfix
Parse the input string of tokens using the given definitions of operators and functions. (Everything else is assumed to be a literal.) Uses the Shunti
parser.go:134
↓ 10 callers
Method
Dequeue
()
parser.go:314
↓ 9 callers
Method
ExposeManyToOne
Adds the necessary NavigationProperty tags to an entity to expose a many-to-one relationship from a (Many) -> b (One). A column name must be provided
providers/mysql.go:269
↓ 8 callers
Function
EmptyParser
()
parser.go:116
↓ 8 callers
Method
Pop
()
parser.go:264
↓ 7 callers
Function
FilterTokenizer
Create a tokenizer capable of tokenizing filter statements
filter_parser.go:50
↓ 7 callers
Method
Peek
()
parser.go:272
↓ 7 callers
Method
PostfixToTree
Convert a Postfix token queue to a parse tree
parser.go:207
↓ 6 callers
Function
BuildService
Create a new service from a given provider. This step builds lookups for all parts of the data model, so constant time lookups can be performed. This
service.go:71
↓ 6 callers
Function
CompareTokens
Check if two slices of tokens are the same.
filter_parser_test.go:161
↓ 6 callers
Method
Json
Serialize the result as JSON for sending to the client. If an error occurs during the serialization, it will be returned.
response_model.go:16
↓ 6 callers
Function
ParseExpandString
(expand string)
expand_parser.go:46
↓ 6 callers
Function
ParseRequest
Parse a request from the HTTP server and format it into a GoDaataRequest type to be passed to a provider to produce a result.
url_parser.go:10
↓ 5 callers
Method
Bytes
()
metadata_model.go:28
↓ 5 callers
Method
Empty
()
parser.go:364
↓ 5 callers
Method
Push
(t *Token)
parser.go:257
↓ 5 callers
Function
SemanticizeRequest
Compare a request to a given service, and validate the semantics and update the request with semantics included
url_parser.go:26
↓ 4 callers
Method
Pop
()
parser.go:354
↓ 4 callers
Method
String
()
parser.go:280
↓ 3 callers
Method
ExposeManyToMany
Adds the necessary NavigationProperty tags to entities to expose a many-to-many relationship from a (Many) -> b (Many). A third table must be provided
providers/mysql.go:290
↓ 3 callers
Method
LookupEntityType
Lookup an entity type from the service metadata. Accepts a fully qualified name, e.g., ODataService.EntityTypeName or, if unambiguous, accepts a simpl
service.go:327
↓ 3 callers
Method
Push
(n *ParseNode)
parser.go:349
↓ 3 callers
Function
SemanticizeExpandQuery
( expand *GoDataExpandQuery, service *GoDataService, entity *GoDataEntityType, )
expand_parser.go:240
↓ 3 callers
Function
SemanticizeSelectQuery
(sel *GoDataSelectQuery, service *GoDataService, entity *GoDataEntityType)
select_parser.go:28
↓ 2 callers
Method
BuildMetadata
Build the $metadata file from the entities in the builder. It creates a schema with the given namespace name.
providers/mysql.go:200
↓ 2 callers
Function
BuildMySQLProvider
Build an empty MySQL provider. Provide the connection parameters and the namespace name.
providers/mysql.go:113
↓ 2 callers
Method
ExposeProperty
Expose an OData property on an entity. You must provide a corresponding table column in the database.
providers/mysql.go:325
↓ 2 callers
Method
GetCount
Request the number of entities in a collection, disregarding any filter query parameters.
service.go:27
↓ 2 callers
Method
GetMetadata
Get the object model representation from the provider.
service.go:29
↓ 2 callers
Method
Ignore
(pattern string, token int)
parser.go:45
↓ 2 callers
Function
InternalServerError
(message string)
errors.go:32
↓ 2 callers
Function
ParseExpandItem
(input tokenQueue)
expand_parser.go:98
↓ 2 callers
Function
ParseExpandOption
(queue *tokenQueue, item *ExpandItem)
expand_parser.go:158
↓ 2 callers
Function
ParseFilterString
Convert an input string from the $filter part of the URL into a parse tree that can be used by providers to create a response.
filter_parser.go:32
↓ 2 callers
Function
ParseIdentifiers
(segment string)
url_parser.go:293
↓ 2 callers
Function
ParseName
(segment string)
url_parser.go:315
↓ 2 callers
Function
ParseOrderByString
(orderby string)
orderby_parser.go:17
↓ 2 callers
Function
ParseSearchString
Convert an input string from the $filter part of the URL into a parse tree that can be used by providers to create a response.
search_parser.go:16
↓ 2 callers
Function
ParseSelectString
(sel string)
select_parser.go:12
↓ 2 callers
Function
ParseSkipString
(skip string)
topskip_parser.go:13
↓ 2 callers
Function
ParseTopString
(top string)
topskip_parser.go:7
↓ 2 callers
Method
Peek
()
parser.go:360
↓ 2 callers
Function
SearchTokenizer
Create a tokenizer capable of tokenizing filter statements
search_parser.go:33
↓ 2 callers
Function
SemanticizeFilterQuery
( filter *GoDataFilterQuery, service *GoDataService, entity *GoDataEntityType, )
filter_parser.go:139
↓ 2 callers
Function
SemanticizeOrderByQuery
(orderby *GoDataOrderByQuery, service *GoDataService, entity *GoDataEntityType)
orderby_parser.go:41
↓ 2 callers
Function
prepareJsonDict
(d map[string]*GoDataResponseField)
response_model.go:64
↓ 2 callers
Function
prepareJsonString
(s []byte)
response_model.go:54
↓ 1 callers
Method
BuildFromClause
Build the from clause in the query, and also return the values to send to the prepared statement.
providers/mysql.go:154
↓ 1 callers
Method
BuildSelectClause
Build the select clause to begin the query, and also return the values to send to a prepared statement.
providers/mysql.go:148
↓ 1 callers
Method
Empty
()
parser.go:326
↓ 1 callers
Function
ExpandTokenizer
()
expand_parser.go:33
↓ 1 callers
Function
FilterParser
()
filter_parser.go:79
↓ 1 callers
Method
GetEntity
Request a single entity from the provider. Should return a response field that contains the value mapping properties to values for the entity.
service.go:20
↓ 1 callers
Method
GetEntityCollection
Request a collection of entities from the provider. Should return a response field that contains the value of a slice of every entity in the collectio
service.go:24
↓ 1 callers
Method
ListenAndServe
Start the service listening on the given address.
service.go:319
↓ 1 callers
Method
LookupEntitySet
Lookup an entity set from the service metadata. Accepts a fully qualified name, e.g., ODataService.ContainerName.EntitySetName, ContainerName.EntitySe
service.go:372
↓ 1 callers
Function
ParseApplyString
(apply string)
apply_parser.go:3
↓ 1 callers
Function
ParseCountString
(count string)
count_parser.go:7
↓ 1 callers
Function
ParseInlineCountString
(inlinecount string)
inlinecount_parser.go:8
↓ 1 callers
Function
ParseUrlPath
(path string)
url_parser.go:85
↓ 1 callers
Function
ParseUrlQuery
(query url.Values)
url_parser.go:207
↓ 1 callers
Function
SearchParser
()
search_parser.go:45
↓ 1 callers
Function
SemanticizePathSegment
(segment *GoDataSegment, service *GoDataService)
url_parser.go:108
↓ 1 callers
Method
TokenizeBytes
(target []byte)
parser.go:51
↓ 1 callers
Method
buildCollectionResponse
(request *GoDataRequest)
service.go:198
↓ 1 callers
Method
buildCountResponse
(request *GoDataRequest)
service.go:294
↓ 1 callers
Method
buildEntityResponse
(request *GoDataRequest)
service.go:246
↓ 1 callers
Method
buildMetadataResponse
(request *GoDataRequest)
service.go:189
↓ 1 callers
Method
buildPropertyResponse
(request *GoDataRequest)
service.go:284
↓ 1 callers
Method
buildPropertyValueResponse
(request *GoDataRequest)
service.go:289
↓ 1 callers
Method
buildRefResponse
(request *GoDataRequest)
service.go:313
↓ 1 callers
Method
buildServiceResponse
(request *GoDataRequest)
service.go:193
↓ 1 callers
Function
prepareJsonList
(l []*GoDataResponseField)
response_model.go:87
↓ 1 callers
Function
semanticizeExpandItem
( item *ExpandItem, service *GoDataService, entity *GoDataEntityType, )
expand_parser.go:303
Function
AuthorizationMiddleware
()
example/main.go:15
Function
BenchmarkBuildProvider
(b *testing.B)
service_test.go:239
Function
BenchmarkBuildTree
(b *testing.B)
parser_test.go:268
Function
BenchmarkCoffeeDatabase
(b *testing.B)
providers/mysql_test.go:160
Function
BenchmarkFilterTokenizer
(b *testing.B)
filter_parser_test.go:152
Function
BenchmarkPEMDAS
(b *testing.B)
parser_test.go:62
Function
BenchmarkTypicalParseSemanticizeRequest
(b *testing.B)
service_test.go:252
Function
BenchmarkWildcardParseSemanticizeRequest
(b *testing.B)
service_test.go:289
Method
BuildQuery
(r *GoDataRequest)
providers/mysql.go:121
Method
BuildWhereClause
Build a where clause that can be appended to an SQL query, and also return the values to send to a prepared statement.
providers/mysql.go:160
Function
CacheMiddleware
()
example/main.go:11
next →
1–100 of 141, ranked by callers