Documentation ¶
Overview ¶
Package v1 is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Index ¶
- Variables
- func RegisterFinder2DHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterFinder2DHandlerClient(ctx context.Context, mux *runtime.ServeMux, client Finder2DClient) error
- func RegisterFinder2DHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterFinder2DServer(s *grpc.Server, srv Finder2DServer)
- type Finder2DClient
- type Finder2DServer
- type GetMatchRequest
- func (*GetMatchRequest) Descriptor() ([]byte, []int)
- func (m *GetMatchRequest) GetApi() string
- func (m *GetMatchRequest) GetId() int32
- func (*GetMatchRequest) ProtoMessage()
- func (m *GetMatchRequest) Reset()
- func (m *GetMatchRequest) String() string
- func (m *GetMatchRequest) XXX_DiscardUnknown()
- func (m *GetMatchRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GetMatchRequest) XXX_Merge(src proto.Message)
- func (m *GetMatchRequest) XXX_Size() int
- func (m *GetMatchRequest) XXX_Unmarshal(b []byte) error
- type GetMatchResponse
- func (*GetMatchResponse) Descriptor() ([]byte, []int)
- func (m *GetMatchResponse) GetApi() string
- func (m *GetMatchResponse) GetMatch() *Match
- func (m *GetMatchResponse) GetMatrix() *Matrix
- func (*GetMatchResponse) ProtoMessage()
- func (m *GetMatchResponse) Reset()
- func (m *GetMatchResponse) String() string
- func (m *GetMatchResponse) XXX_DiscardUnknown()
- func (m *GetMatchResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GetMatchResponse) XXX_Merge(src proto.Message)
- func (m *GetMatchResponse) XXX_Size() int
- func (m *GetMatchResponse) XXX_Unmarshal(b []byte) error
- type GetMatchesRequest
- func (*GetMatchesRequest) Descriptor() ([]byte, []int)
- func (m *GetMatchesRequest) GetApi() string
- func (*GetMatchesRequest) ProtoMessage()
- func (m *GetMatchesRequest) Reset()
- func (m *GetMatchesRequest) String() string
- func (m *GetMatchesRequest) XXX_DiscardUnknown()
- func (m *GetMatchesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GetMatchesRequest) XXX_Merge(src proto.Message)
- func (m *GetMatchesRequest) XXX_Size() int
- func (m *GetMatchesRequest) XXX_Unmarshal(b []byte) error
- type GetMatchesResponse
- func (*GetMatchesResponse) Descriptor() ([]byte, []int)
- func (m *GetMatchesResponse) GetApi() string
- func (m *GetMatchesResponse) GetMatches() []*Match
- func (*GetMatchesResponse) ProtoMessage()
- func (m *GetMatchesResponse) Reset()
- func (m *GetMatchesResponse) String() string
- func (m *GetMatchesResponse) XXX_DiscardUnknown()
- func (m *GetMatchesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GetMatchesResponse) XXX_Merge(src proto.Message)
- func (m *GetMatchesResponse) XXX_Size() int
- func (m *GetMatchesResponse) XXX_Unmarshal(b []byte) error
- type GetMatrixRequest
- func (*GetMatrixRequest) Descriptor() ([]byte, []int)
- func (m *GetMatrixRequest) GetApi() string
- func (m *GetMatrixRequest) GetName() MatrixName
- func (*GetMatrixRequest) ProtoMessage()
- func (m *GetMatrixRequest) Reset()
- func (m *GetMatrixRequest) String() string
- func (m *GetMatrixRequest) XXX_DiscardUnknown()
- func (m *GetMatrixRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GetMatrixRequest) XXX_Merge(src proto.Message)
- func (m *GetMatrixRequest) XXX_Size() int
- func (m *GetMatrixRequest) XXX_Unmarshal(b []byte) error
- type GetMatrixResponse
- func (*GetMatrixResponse) Descriptor() ([]byte, []int)
- func (m *GetMatrixResponse) GetApi() string
- func (m *GetMatrixResponse) GetMatrix() *Matrix
- func (m *GetMatrixResponse) GetName() MatrixName
- func (*GetMatrixResponse) ProtoMessage()
- func (m *GetMatrixResponse) Reset()
- func (m *GetMatrixResponse) String() string
- func (m *GetMatrixResponse) XXX_DiscardUnknown()
- func (m *GetMatrixResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GetMatrixResponse) XXX_Merge(src proto.Message)
- func (m *GetMatrixResponse) XXX_Size() int
- func (m *GetMatrixResponse) XXX_Unmarshal(b []byte) error
- type LoadMatrixRequest
- func (*LoadMatrixRequest) Descriptor() ([]byte, []int)
- func (m *LoadMatrixRequest) GetApi() string
- func (m *LoadMatrixRequest) GetMatrix() *Matrix
- func (m *LoadMatrixRequest) GetName() MatrixName
- func (*LoadMatrixRequest) ProtoMessage()
- func (m *LoadMatrixRequest) Reset()
- func (m *LoadMatrixRequest) String() string
- func (m *LoadMatrixRequest) XXX_DiscardUnknown()
- func (m *LoadMatrixRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *LoadMatrixRequest) XXX_Merge(src proto.Message)
- func (m *LoadMatrixRequest) XXX_Size() int
- func (m *LoadMatrixRequest) XXX_Unmarshal(b []byte) error
- type LoadMatrixResponse
- func (*LoadMatrixResponse) Descriptor() ([]byte, []int)
- func (m *LoadMatrixResponse) GetApi() string
- func (*LoadMatrixResponse) ProtoMessage()
- func (m *LoadMatrixResponse) Reset()
- func (m *LoadMatrixResponse) String() string
- func (m *LoadMatrixResponse) XXX_DiscardUnknown()
- func (m *LoadMatrixResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *LoadMatrixResponse) XXX_Merge(src proto.Message)
- func (m *LoadMatrixResponse) XXX_Size() int
- func (m *LoadMatrixResponse) XXX_Unmarshal(b []byte) error
- type Match
- func (*Match) Descriptor() ([]byte, []int)
- func (m *Match) GetPercentage() float32
- func (m *Match) GetX() int32
- func (m *Match) GetY() int32
- func (*Match) ProtoMessage()
- func (m *Match) Reset()
- func (m *Match) String() string
- func (m *Match) XXX_DiscardUnknown()
- func (m *Match) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Match) XXX_Merge(src proto.Message)
- func (m *Match) XXX_Size() int
- func (m *Match) XXX_Unmarshal(b []byte) error
- type Matrix
- func (*Matrix) Descriptor() ([]byte, []int)
- func (m *Matrix) GetContent() string
- func (m *Matrix) GetHeight() int32
- func (m *Matrix) GetWidth() int32
- func (*Matrix) ProtoMessage()
- func (m *Matrix) Reset()
- func (m *Matrix) String() string
- func (m *Matrix) XXX_DiscardUnknown()
- func (m *Matrix) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Matrix) XXX_Merge(src proto.Message)
- func (m *Matrix) XXX_Size() int
- func (m *Matrix) XXX_Unmarshal(b []byte) error
- type MatrixName
- type SearchRequest
- func (*SearchRequest) Descriptor() ([]byte, []int)
- func (m *SearchRequest) GetApi() string
- func (m *SearchRequest) GetDelta() int32
- func (m *SearchRequest) GetPercentage() float32
- func (*SearchRequest) ProtoMessage()
- func (m *SearchRequest) Reset()
- func (m *SearchRequest) String() string
- func (m *SearchRequest) XXX_DiscardUnknown()
- func (m *SearchRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SearchRequest) XXX_Merge(src proto.Message)
- func (m *SearchRequest) XXX_Size() int
- func (m *SearchRequest) XXX_Unmarshal(b []byte) error
- type SearchResponse
- func (*SearchResponse) Descriptor() ([]byte, []int)
- func (m *SearchResponse) GetApi() string
- func (m *SearchResponse) GetTotalMatches() int32
- func (*SearchResponse) ProtoMessage()
- func (m *SearchResponse) Reset()
- func (m *SearchResponse) String() string
- func (m *SearchResponse) XXX_DiscardUnknown()
- func (m *SearchResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SearchResponse) XXX_Merge(src proto.Message)
- func (m *SearchResponse) XXX_Size() int
- func (m *SearchResponse) XXX_Unmarshal(b []byte) error
- type UnimplementedFinder2DServer
- func (*UnimplementedFinder2DServer) GetMatch(ctx context.Context, req *GetMatchRequest) (*GetMatchResponse, error)
- func (*UnimplementedFinder2DServer) GetMatches(ctx context.Context, req *GetMatchesRequest) (*GetMatchesResponse, error)
- func (*UnimplementedFinder2DServer) GetMatrix(ctx context.Context, req *GetMatrixRequest) (*GetMatrixResponse, error)
- func (*UnimplementedFinder2DServer) LoadMatrix(ctx context.Context, req *LoadMatrixRequest) (*LoadMatrixResponse, error)
- func (*UnimplementedFinder2DServer) Search(ctx context.Context, req *SearchRequest) (*SearchResponse, error)
Constants ¶
This section is empty.
Variables ¶
var MatrixName_name = map[int32]string{
0: "SOURCE",
1: "TARGET",
}
var MatrixName_value = map[string]int32{
"SOURCE": 0,
"TARGET": 1,
}
var Swagger = []byte(`
{
"swagger": "2.0",
"info": {
"title": "Finder2D Service",
"version": "1.0",
"contact": {
"name": "Finder2D",
"url": "https://github.com/johandry/finder2d",
"email": "johandry@gmail.com"
}
},
"schemes": [
"http"
],
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"paths": {
"/api/v1/matches": {
"get": {
"operationId": "GetMatches",
"responses": {
"200": {
"description": "A successful response.",
"schema": {
"$ref": "#/definitions/v1GetMatchesResponse"
}
},
"400": {
"description": "Returned when a request is invalid or missing parameters",
"schema": {}
},
"404": {
"description": "Returned when the target matrix is not found.",
"schema": {
"format": "string"
}
}
},
"parameters": [
{
"name": "api",
"in": "query",
"required": false,
"type": "string"
}
],
"tags": [
"Finder2D"
]
}
},
"/api/v1/matches/{id}": {
"get": {
"operationId": "GetMatch",
"responses": {
"200": {
"description": "A successful response.",
"schema": {
"$ref": "#/definitions/v1GetMatchResponse"
}
},
"400": {
"description": "Returned when a request is invalid or missing parameters",
"schema": {}
},
"404": {
"description": "Returned when the target matrix is not found.",
"schema": {
"format": "string"
}
}
},
"parameters": [
{
"name": "id",
"in": "path",
"required": true,
"type": "integer",
"format": "int32"
},
{
"name": "api",
"in": "query",
"required": false,
"type": "string"
}
],
"tags": [
"Finder2D"
]
}
},
"/api/v1/matrixes/{name}": {
"get": {
"operationId": "GetMatrix",
"responses": {
"200": {
"description": "A successful response.",
"schema": {
"$ref": "#/definitions/v1GetMatrixResponse"
}
},
"400": {
"description": "Returned when a request is invalid or missing parameters",
"schema": {}
},
"404": {
"description": "Returned when the target matrix is not found.",
"schema": {
"format": "string"
}
}
},
"parameters": [
{
"name": "name",
"in": "path",
"required": true,
"type": "string",
"enum": [
"SOURCE",
"TARGET"
]
},
{
"name": "api",
"in": "query",
"required": false,
"type": "string"
}
],
"tags": [
"Finder2D"
]
},
"post": {
"operationId": "LoadMatrix",
"responses": {
"200": {
"description": "A successful response.",
"schema": {
"$ref": "#/definitions/v1LoadMatrixResponse"
}
},
"400": {
"description": "Returned when a request is invalid or missing parameters",
"schema": {}
},
"404": {
"description": "Returned when the target matrix is not found.",
"schema": {
"format": "string"
}
}
},
"parameters": [
{
"name": "name",
"in": "path",
"required": true,
"type": "string",
"enum": [
"SOURCE",
"TARGET"
]
},
{
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/v1LoadMatrixRequest"
}
}
],
"tags": [
"Finder2D"
]
}
},
"/api/v1/search": {
"post": {
"operationId": "Search",
"responses": {
"200": {
"description": "A successful response.",
"schema": {
"$ref": "#/definitions/v1SearchResponse"
}
},
"400": {
"description": "Returned when a request is invalid or missing parameters",
"schema": {}
},
"404": {
"description": "Returned when the target matrix is not found.",
"schema": {
"format": "string"
}
}
},
"parameters": [
{
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/v1SearchRequest"
}
}
],
"tags": [
"Finder2D"
]
}
}
},
"definitions": {
"v1GetMatchResponse": {
"type": "object",
"properties": {
"api": {
"type": "string"
},
"match": {
"$ref": "#/definitions/v1Match"
},
"matrix": {
"$ref": "#/definitions/v1Matrix"
}
}
},
"v1GetMatchesResponse": {
"type": "object",
"properties": {
"api": {
"type": "string"
},
"matches": {
"type": "array",
"items": {
"$ref": "#/definitions/v1Match"
}
}
}
},
"v1GetMatrixResponse": {
"type": "object",
"properties": {
"api": {
"type": "string"
},
"name": {
"$ref": "#/definitions/v1MatrixName"
},
"matrix": {
"$ref": "#/definitions/v1Matrix"
}
}
},
"v1LoadMatrixRequest": {
"type": "object",
"properties": {
"api": {
"type": "string"
},
"name": {
"$ref": "#/definitions/v1MatrixName"
},
"matrix": {
"$ref": "#/definitions/v1Matrix"
}
}
},
"v1LoadMatrixResponse": {
"type": "object",
"properties": {
"api": {
"type": "string"
}
}
},
"v1Match": {
"type": "object",
"properties": {
"x": {
"type": "integer",
"format": "int32"
},
"y": {
"type": "integer",
"format": "int32"
},
"percentage": {
"type": "number",
"format": "float"
}
}
},
"v1Matrix": {
"type": "object",
"properties": {
"width": {
"type": "integer",
"format": "int32"
},
"height": {
"type": "integer",
"format": "int32"
},
"content": {
"type": "string"
}
}
},
"v1MatrixName": {
"type": "string",
"enum": [
"SOURCE",
"TARGET"
],
"default": "SOURCE"
},
"v1SearchRequest": {
"type": "object",
"properties": {
"api": {
"type": "string"
},
"percentage": {
"type": "number",
"format": "float"
},
"delta": {
"type": "integer",
"format": "int32"
}
}
},
"v1SearchResponse": {
"type": "object",
"properties": {
"api": {
"type": "string"
},
"total_matches": {
"type": "integer",
"format": "int32"
}
}
}
},
"externalDocs": {
"description": "Finder2D Documentation",
"url": "https://github.com/johandry/finder2d/blob/master/README.md"
}
}
`)
Functions ¶
func RegisterFinder2DHandler ¶
func RegisterFinder2DHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
RegisterFinder2DHandler registers the http handlers for service Finder2D to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterFinder2DHandlerClient ¶
func RegisterFinder2DHandlerClient(ctx context.Context, mux *runtime.ServeMux, client Finder2DClient) error
RegisterFinder2DHandlerClient registers the http handlers for service Finder2D to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "Finder2DClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "Finder2DClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "Finder2DClient" to call the correct interceptors.
func RegisterFinder2DHandlerFromEndpoint ¶
func RegisterFinder2DHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterFinder2DHandlerFromEndpoint is same as RegisterFinder2DHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterFinder2DServer ¶
func RegisterFinder2DServer(s *grpc.Server, srv Finder2DServer)
Types ¶
type Finder2DClient ¶
type Finder2DClient interface { GetMatrix(ctx context.Context, in *GetMatrixRequest, opts ...grpc.CallOption) (*GetMatrixResponse, error) LoadMatrix(ctx context.Context, in *LoadMatrixRequest, opts ...grpc.CallOption) (*LoadMatrixResponse, error) Search(ctx context.Context, in *SearchRequest, opts ...grpc.CallOption) (*SearchResponse, error) GetMatches(ctx context.Context, in *GetMatchesRequest, opts ...grpc.CallOption) (*GetMatchesResponse, error) GetMatch(ctx context.Context, in *GetMatchRequest, opts ...grpc.CallOption) (*GetMatchResponse, error) }
Finder2DClient is the client API for Finder2D service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewFinder2DClient ¶
func NewFinder2DClient(cc *grpc.ClientConn) Finder2DClient
type Finder2DServer ¶
type Finder2DServer interface { GetMatrix(context.Context, *GetMatrixRequest) (*GetMatrixResponse, error) LoadMatrix(context.Context, *LoadMatrixRequest) (*LoadMatrixResponse, error) Search(context.Context, *SearchRequest) (*SearchResponse, error) GetMatches(context.Context, *GetMatchesRequest) (*GetMatchesResponse, error) GetMatch(context.Context, *GetMatchRequest) (*GetMatchResponse, error) }
Finder2DServer is the server API for Finder2D service.
type GetMatchRequest ¶
type GetMatchRequest struct { Api string `protobuf:"bytes,1,opt,name=api,proto3" json:"api,omitempty"` Id int32 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*GetMatchRequest) Descriptor ¶
func (*GetMatchRequest) Descriptor() ([]byte, []int)
func (*GetMatchRequest) GetApi ¶
func (m *GetMatchRequest) GetApi() string
func (*GetMatchRequest) GetId ¶
func (m *GetMatchRequest) GetId() int32
func (*GetMatchRequest) ProtoMessage ¶
func (*GetMatchRequest) ProtoMessage()
func (*GetMatchRequest) Reset ¶
func (m *GetMatchRequest) Reset()
func (*GetMatchRequest) String ¶
func (m *GetMatchRequest) String() string
func (*GetMatchRequest) XXX_DiscardUnknown ¶
func (m *GetMatchRequest) XXX_DiscardUnknown()
func (*GetMatchRequest) XXX_Marshal ¶
func (m *GetMatchRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GetMatchRequest) XXX_Merge ¶
func (m *GetMatchRequest) XXX_Merge(src proto.Message)
func (*GetMatchRequest) XXX_Size ¶
func (m *GetMatchRequest) XXX_Size() int
func (*GetMatchRequest) XXX_Unmarshal ¶
func (m *GetMatchRequest) XXX_Unmarshal(b []byte) error
type GetMatchResponse ¶
type GetMatchResponse struct { Api string `protobuf:"bytes,1,opt,name=api,proto3" json:"api,omitempty"` Match *Match `protobuf:"bytes,2,opt,name=match,proto3" json:"match,omitempty"` Matrix *Matrix `protobuf:"bytes,3,opt,name=matrix,proto3" json:"matrix,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*GetMatchResponse) Descriptor ¶
func (*GetMatchResponse) Descriptor() ([]byte, []int)
func (*GetMatchResponse) GetApi ¶
func (m *GetMatchResponse) GetApi() string
func (*GetMatchResponse) GetMatch ¶
func (m *GetMatchResponse) GetMatch() *Match
func (*GetMatchResponse) GetMatrix ¶
func (m *GetMatchResponse) GetMatrix() *Matrix
func (*GetMatchResponse) ProtoMessage ¶
func (*GetMatchResponse) ProtoMessage()
func (*GetMatchResponse) Reset ¶
func (m *GetMatchResponse) Reset()
func (*GetMatchResponse) String ¶
func (m *GetMatchResponse) String() string
func (*GetMatchResponse) XXX_DiscardUnknown ¶
func (m *GetMatchResponse) XXX_DiscardUnknown()
func (*GetMatchResponse) XXX_Marshal ¶
func (m *GetMatchResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GetMatchResponse) XXX_Merge ¶
func (m *GetMatchResponse) XXX_Merge(src proto.Message)
func (*GetMatchResponse) XXX_Size ¶
func (m *GetMatchResponse) XXX_Size() int
func (*GetMatchResponse) XXX_Unmarshal ¶
func (m *GetMatchResponse) XXX_Unmarshal(b []byte) error
type GetMatchesRequest ¶
type GetMatchesRequest struct { Api string `protobuf:"bytes,1,opt,name=api,proto3" json:"api,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*GetMatchesRequest) Descriptor ¶
func (*GetMatchesRequest) Descriptor() ([]byte, []int)
func (*GetMatchesRequest) GetApi ¶
func (m *GetMatchesRequest) GetApi() string
func (*GetMatchesRequest) ProtoMessage ¶
func (*GetMatchesRequest) ProtoMessage()
func (*GetMatchesRequest) Reset ¶
func (m *GetMatchesRequest) Reset()
func (*GetMatchesRequest) String ¶
func (m *GetMatchesRequest) String() string
func (*GetMatchesRequest) XXX_DiscardUnknown ¶
func (m *GetMatchesRequest) XXX_DiscardUnknown()
func (*GetMatchesRequest) XXX_Marshal ¶
func (m *GetMatchesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GetMatchesRequest) XXX_Merge ¶
func (m *GetMatchesRequest) XXX_Merge(src proto.Message)
func (*GetMatchesRequest) XXX_Size ¶
func (m *GetMatchesRequest) XXX_Size() int
func (*GetMatchesRequest) XXX_Unmarshal ¶
func (m *GetMatchesRequest) XXX_Unmarshal(b []byte) error
type GetMatchesResponse ¶
type GetMatchesResponse struct { Api string `protobuf:"bytes,1,opt,name=api,proto3" json:"api,omitempty"` Matches []*Match `protobuf:"bytes,2,rep,name=matches,proto3" json:"matches,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*GetMatchesResponse) Descriptor ¶
func (*GetMatchesResponse) Descriptor() ([]byte, []int)
func (*GetMatchesResponse) GetApi ¶
func (m *GetMatchesResponse) GetApi() string
func (*GetMatchesResponse) GetMatches ¶
func (m *GetMatchesResponse) GetMatches() []*Match
func (*GetMatchesResponse) ProtoMessage ¶
func (*GetMatchesResponse) ProtoMessage()
func (*GetMatchesResponse) Reset ¶
func (m *GetMatchesResponse) Reset()
func (*GetMatchesResponse) String ¶
func (m *GetMatchesResponse) String() string
func (*GetMatchesResponse) XXX_DiscardUnknown ¶
func (m *GetMatchesResponse) XXX_DiscardUnknown()
func (*GetMatchesResponse) XXX_Marshal ¶
func (m *GetMatchesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GetMatchesResponse) XXX_Merge ¶
func (m *GetMatchesResponse) XXX_Merge(src proto.Message)
func (*GetMatchesResponse) XXX_Size ¶
func (m *GetMatchesResponse) XXX_Size() int
func (*GetMatchesResponse) XXX_Unmarshal ¶
func (m *GetMatchesResponse) XXX_Unmarshal(b []byte) error
type GetMatrixRequest ¶
type GetMatrixRequest struct { Api string `protobuf:"bytes,1,opt,name=api,proto3" json:"api,omitempty"` Name MatrixName `protobuf:"varint,2,opt,name=name,proto3,enum=finder2d.v1.MatrixName" json:"name,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*GetMatrixRequest) Descriptor ¶
func (*GetMatrixRequest) Descriptor() ([]byte, []int)
func (*GetMatrixRequest) GetApi ¶
func (m *GetMatrixRequest) GetApi() string
func (*GetMatrixRequest) GetName ¶
func (m *GetMatrixRequest) GetName() MatrixName
func (*GetMatrixRequest) ProtoMessage ¶
func (*GetMatrixRequest) ProtoMessage()
func (*GetMatrixRequest) Reset ¶
func (m *GetMatrixRequest) Reset()
func (*GetMatrixRequest) String ¶
func (m *GetMatrixRequest) String() string
func (*GetMatrixRequest) XXX_DiscardUnknown ¶
func (m *GetMatrixRequest) XXX_DiscardUnknown()
func (*GetMatrixRequest) XXX_Marshal ¶
func (m *GetMatrixRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GetMatrixRequest) XXX_Merge ¶
func (m *GetMatrixRequest) XXX_Merge(src proto.Message)
func (*GetMatrixRequest) XXX_Size ¶
func (m *GetMatrixRequest) XXX_Size() int
func (*GetMatrixRequest) XXX_Unmarshal ¶
func (m *GetMatrixRequest) XXX_Unmarshal(b []byte) error
type GetMatrixResponse ¶
type GetMatrixResponse struct { Api string `protobuf:"bytes,1,opt,name=api,proto3" json:"api,omitempty"` Name MatrixName `protobuf:"varint,2,opt,name=name,proto3,enum=finder2d.v1.MatrixName" json:"name,omitempty"` Matrix *Matrix `protobuf:"bytes,3,opt,name=matrix,proto3" json:"matrix,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*GetMatrixResponse) Descriptor ¶
func (*GetMatrixResponse) Descriptor() ([]byte, []int)
func (*GetMatrixResponse) GetApi ¶
func (m *GetMatrixResponse) GetApi() string
func (*GetMatrixResponse) GetMatrix ¶
func (m *GetMatrixResponse) GetMatrix() *Matrix
func (*GetMatrixResponse) GetName ¶
func (m *GetMatrixResponse) GetName() MatrixName
func (*GetMatrixResponse) ProtoMessage ¶
func (*GetMatrixResponse) ProtoMessage()
func (*GetMatrixResponse) Reset ¶
func (m *GetMatrixResponse) Reset()
func (*GetMatrixResponse) String ¶
func (m *GetMatrixResponse) String() string
func (*GetMatrixResponse) XXX_DiscardUnknown ¶
func (m *GetMatrixResponse) XXX_DiscardUnknown()
func (*GetMatrixResponse) XXX_Marshal ¶
func (m *GetMatrixResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GetMatrixResponse) XXX_Merge ¶
func (m *GetMatrixResponse) XXX_Merge(src proto.Message)
func (*GetMatrixResponse) XXX_Size ¶
func (m *GetMatrixResponse) XXX_Size() int
func (*GetMatrixResponse) XXX_Unmarshal ¶
func (m *GetMatrixResponse) XXX_Unmarshal(b []byte) error
type LoadMatrixRequest ¶
type LoadMatrixRequest struct { Api string `protobuf:"bytes,1,opt,name=api,proto3" json:"api,omitempty"` Name MatrixName `protobuf:"varint,2,opt,name=name,proto3,enum=finder2d.v1.MatrixName" json:"name,omitempty"` Matrix *Matrix `protobuf:"bytes,3,opt,name=matrix,proto3" json:"matrix,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*LoadMatrixRequest) Descriptor ¶
func (*LoadMatrixRequest) Descriptor() ([]byte, []int)
func (*LoadMatrixRequest) GetApi ¶
func (m *LoadMatrixRequest) GetApi() string
func (*LoadMatrixRequest) GetMatrix ¶
func (m *LoadMatrixRequest) GetMatrix() *Matrix
func (*LoadMatrixRequest) GetName ¶
func (m *LoadMatrixRequest) GetName() MatrixName
func (*LoadMatrixRequest) ProtoMessage ¶
func (*LoadMatrixRequest) ProtoMessage()
func (*LoadMatrixRequest) Reset ¶
func (m *LoadMatrixRequest) Reset()
func (*LoadMatrixRequest) String ¶
func (m *LoadMatrixRequest) String() string
func (*LoadMatrixRequest) XXX_DiscardUnknown ¶
func (m *LoadMatrixRequest) XXX_DiscardUnknown()
func (*LoadMatrixRequest) XXX_Marshal ¶
func (m *LoadMatrixRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*LoadMatrixRequest) XXX_Merge ¶
func (m *LoadMatrixRequest) XXX_Merge(src proto.Message)
func (*LoadMatrixRequest) XXX_Size ¶
func (m *LoadMatrixRequest) XXX_Size() int
func (*LoadMatrixRequest) XXX_Unmarshal ¶
func (m *LoadMatrixRequest) XXX_Unmarshal(b []byte) error
type LoadMatrixResponse ¶
type LoadMatrixResponse struct { Api string `protobuf:"bytes,1,opt,name=api,proto3" json:"api,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*LoadMatrixResponse) Descriptor ¶
func (*LoadMatrixResponse) Descriptor() ([]byte, []int)
func (*LoadMatrixResponse) GetApi ¶
func (m *LoadMatrixResponse) GetApi() string
func (*LoadMatrixResponse) ProtoMessage ¶
func (*LoadMatrixResponse) ProtoMessage()
func (*LoadMatrixResponse) Reset ¶
func (m *LoadMatrixResponse) Reset()
func (*LoadMatrixResponse) String ¶
func (m *LoadMatrixResponse) String() string
func (*LoadMatrixResponse) XXX_DiscardUnknown ¶
func (m *LoadMatrixResponse) XXX_DiscardUnknown()
func (*LoadMatrixResponse) XXX_Marshal ¶
func (m *LoadMatrixResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*LoadMatrixResponse) XXX_Merge ¶
func (m *LoadMatrixResponse) XXX_Merge(src proto.Message)
func (*LoadMatrixResponse) XXX_Size ¶
func (m *LoadMatrixResponse) XXX_Size() int
func (*LoadMatrixResponse) XXX_Unmarshal ¶
func (m *LoadMatrixResponse) XXX_Unmarshal(b []byte) error
type Match ¶
type Match struct { X int32 `protobuf:"varint,1,opt,name=x,proto3" json:"x,omitempty"` Y int32 `protobuf:"varint,2,opt,name=y,proto3" json:"y,omitempty"` Percentage float32 `protobuf:"fixed32,3,opt,name=percentage,proto3" json:"percentage,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*Match) Descriptor ¶
func (*Match) GetPercentage ¶
func (*Match) ProtoMessage ¶
func (*Match) ProtoMessage()
func (*Match) XXX_DiscardUnknown ¶
func (m *Match) XXX_DiscardUnknown()
func (*Match) XXX_Marshal ¶
func (*Match) XXX_Unmarshal ¶
type Matrix ¶
type Matrix struct { Width int32 `protobuf:"varint,3,opt,name=width,proto3" json:"width,omitempty"` Height int32 `protobuf:"varint,4,opt,name=height,proto3" json:"height,omitempty"` Content string `protobuf:"bytes,5,opt,name=content,proto3" json:"content,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*Matrix) Descriptor ¶
func (*Matrix) GetContent ¶
func (*Matrix) ProtoMessage ¶
func (*Matrix) ProtoMessage()
func (*Matrix) XXX_DiscardUnknown ¶
func (m *Matrix) XXX_DiscardUnknown()
func (*Matrix) XXX_Marshal ¶
func (*Matrix) XXX_Unmarshal ¶
type MatrixName ¶
type MatrixName int32
const ( MatrixName_SOURCE MatrixName = 0 MatrixName_TARGET MatrixName = 1 )
func (MatrixName) EnumDescriptor ¶
func (MatrixName) EnumDescriptor() ([]byte, []int)
func (MatrixName) String ¶
func (x MatrixName) String() string
type SearchRequest ¶
type SearchRequest struct { Api string `protobuf:"bytes,1,opt,name=api,proto3" json:"api,omitempty"` Percentage float32 `protobuf:"fixed32,2,opt,name=percentage,proto3" json:"percentage,omitempty"` Delta int32 `protobuf:"varint,3,opt,name=delta,proto3" json:"delta,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SearchRequest) Descriptor ¶
func (*SearchRequest) Descriptor() ([]byte, []int)
func (*SearchRequest) GetApi ¶
func (m *SearchRequest) GetApi() string
func (*SearchRequest) GetDelta ¶
func (m *SearchRequest) GetDelta() int32
func (*SearchRequest) GetPercentage ¶
func (m *SearchRequest) GetPercentage() float32
func (*SearchRequest) ProtoMessage ¶
func (*SearchRequest) ProtoMessage()
func (*SearchRequest) Reset ¶
func (m *SearchRequest) Reset()
func (*SearchRequest) String ¶
func (m *SearchRequest) String() string
func (*SearchRequest) XXX_DiscardUnknown ¶
func (m *SearchRequest) XXX_DiscardUnknown()
func (*SearchRequest) XXX_Marshal ¶
func (m *SearchRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SearchRequest) XXX_Merge ¶
func (m *SearchRequest) XXX_Merge(src proto.Message)
func (*SearchRequest) XXX_Size ¶
func (m *SearchRequest) XXX_Size() int
func (*SearchRequest) XXX_Unmarshal ¶
func (m *SearchRequest) XXX_Unmarshal(b []byte) error
type SearchResponse ¶
type SearchResponse struct { Api string `protobuf:"bytes,1,opt,name=api,proto3" json:"api,omitempty"` TotalMatches int32 `protobuf:"varint,2,opt,name=total_matches,json=totalMatches,proto3" json:"total_matches,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SearchResponse) Descriptor ¶
func (*SearchResponse) Descriptor() ([]byte, []int)
func (*SearchResponse) GetApi ¶
func (m *SearchResponse) GetApi() string
func (*SearchResponse) GetTotalMatches ¶
func (m *SearchResponse) GetTotalMatches() int32
func (*SearchResponse) ProtoMessage ¶
func (*SearchResponse) ProtoMessage()
func (*SearchResponse) Reset ¶
func (m *SearchResponse) Reset()
func (*SearchResponse) String ¶
func (m *SearchResponse) String() string
func (*SearchResponse) XXX_DiscardUnknown ¶
func (m *SearchResponse) XXX_DiscardUnknown()
func (*SearchResponse) XXX_Marshal ¶
func (m *SearchResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SearchResponse) XXX_Merge ¶
func (m *SearchResponse) XXX_Merge(src proto.Message)
func (*SearchResponse) XXX_Size ¶
func (m *SearchResponse) XXX_Size() int
func (*SearchResponse) XXX_Unmarshal ¶
func (m *SearchResponse) XXX_Unmarshal(b []byte) error
type UnimplementedFinder2DServer ¶
type UnimplementedFinder2DServer struct { }
UnimplementedFinder2DServer can be embedded to have forward compatible implementations.
func (*UnimplementedFinder2DServer) GetMatch ¶
func (*UnimplementedFinder2DServer) GetMatch(ctx context.Context, req *GetMatchRequest) (*GetMatchResponse, error)
func (*UnimplementedFinder2DServer) GetMatches ¶
func (*UnimplementedFinder2DServer) GetMatches(ctx context.Context, req *GetMatchesRequest) (*GetMatchesResponse, error)
func (*UnimplementedFinder2DServer) GetMatrix ¶
func (*UnimplementedFinder2DServer) GetMatrix(ctx context.Context, req *GetMatrixRequest) (*GetMatrixResponse, error)
func (*UnimplementedFinder2DServer) LoadMatrix ¶
func (*UnimplementedFinder2DServer) LoadMatrix(ctx context.Context, req *LoadMatrixRequest) (*LoadMatrixResponse, error)
func (*UnimplementedFinder2DServer) Search ¶
func (*UnimplementedFinder2DServer) Search(ctx context.Context, req *SearchRequest) (*SearchResponse, error)