Documentation ¶
Index ¶
- Variables
- func DefaultGrpcServer(registerComponents func(*grpc.Server))
- func GetGrpcConn(connectionString string) (*grpc.ClientConn, error)
- func GetPluginSources(Id string, name string, uri string, uriType string) (int, error)
- func JwtMiddleware(publicKey *rsa.PublicKey, mode string) gin.HandlerFunc
- func RBACMiddleware(rbacService string, resource string, operations []string) gin.HandlerFunc
- func SetEnv(mode *string)
- type CustomQuestions
- type Exam
- type GinErrorList
- type Grid
- type Layout
- type Plugin
- type PooledQuestions
- type PooledSetQuestions
- type QuestionConfig
- type Section
- type SectionIntermediate
- type SectionSwitch
- type ServerSide
- type SetQuestions
- type StandardErrorList
- type StandardQuestions
- type UserJWT
Constants ¶
This section is empty.
Variables ¶
View Source
var ( GinErrors = GinErrorList{ ServiceConnection: gin.H{ "error": "could not connect to internal service", }, UnknownError: gin.H{ "error": "an unknown error occurred", }, JsonParseError: gin.H{ "error": "could not parse JSON", }, } Errors = StandardErrorList{ ServiceConnection: errors.New("could not connect to service"), UnknownError: errors.New("an unknown error occurred"), } Db *sql.DB )
Functions ¶
func DefaultGrpcServer ¶
func GetGrpcConn ¶
func GetGrpcConn(connectionString string) (*grpc.ClientConn, error)
func GetPluginSources ¶
func JwtMiddleware ¶
func JwtMiddleware(publicKey *rsa.PublicKey, mode string) gin.HandlerFunc
func RBACMiddleware ¶
func RBACMiddleware(rbacService string, resource string, operations []string) gin.HandlerFunc
Types ¶
type CustomQuestions ¶
type Exam ¶
type Exam struct {
Sections []SectionIntermediate
}
type GinErrorList ¶
type PooledQuestions ¶
type PooledSetQuestions ¶
type QuestionConfig ¶
type QuestionConfig struct { SectionSwitch *StandardQuestions *PooledQuestions *SetQuestions *PooledSetQuestions *CustomQuestions }
func (*QuestionConfig) UnmarshalJSON ¶
func (res *QuestionConfig) UnmarshalJSON(data []byte) error
type Section ¶
type Section struct { Name string `json:"name"` SectionSwitch QuestionConfig QuestionConfig `json:"questionConfig"` Layout Layout `json:"layout"` }
type SectionIntermediate ¶
type SectionIntermediate struct {
Section
}
func (*SectionIntermediate) UnmarshalJSON ¶
func (res *SectionIntermediate) UnmarshalJSON(data []byte) error
type SectionSwitch ¶
type SectionSwitch struct {
SectionType string
}
type ServerSide ¶
type SetQuestions ¶
type SetQuestions struct {
Sets []int `json:"sets"`
}
type StandardErrorList ¶
type StandardQuestions ¶
type StandardQuestions struct {
Questions []uint64 `json:"questions"`
}
Click to show internal directories.
Click to hide internal directories.