Documentation
¶
Index ¶
- Variables
- type Class
- type Index
- type Major
- type Minor
- func (m Minor) Description() string
- func (m Minor) InBounds() bool
- func (m Minor) Indexes() []Index
- func (m Minor) Major() Major
- func (m Minor) MustRegisterIndex(name string, description ...string) Index
- func (m Minor) Name() string
- func (m Minor) RegisterIndex(name string, description ...string) (Index, error)
- func (m Minor) Valid() bool
- func (m Minor) Value() uint16
Constants ¶
This section is empty.
Variables ¶
var ( // MnrCommonParse is the 'MjrCommon' minor error classification // for parsing common strings. MnrCommonParse Minor // CommonParseBrackets is the 'MjrCommon', 'MnrCommonParse' error classification // for parsing bracketed strings. CommonParseBrackets Class // MnrCommonLogger is the 'MjrCommon' minor error classification // for logger issues. MnrCommonLogger Minor // CommonLoggerNotImplement is the 'MjrCommon', 'MnrCommonLogger' error classification // for logger's that doesn't implement some interface. CommonLoggerNotImplement Class // CommonLoggerUnknownLevel is the 'MjrCommon', 'MnrCommonLogger' error classification // for unknown level logger. CommonLoggerUnknownLevel Class )
var ( // MnrConfigRead is the 'MjrConfig' minor error classification // for the config read issues. MnrConfigRead Minor // ConfigReadNotFound is the 'MjrConfig', 'MnrConfigRead' error classification // for the read config not found issue. ConfigReadNotFound Class )
var ( // MnrConfigValue is the 'MjrConfig' minor error classification // for the config value issues. MnrConfigValue Minor // ConfigValueGateway is the 'MjrConfig', 'MnrConfigValue' error classification // for the issues with the value of gateway. ConfigValueGateway Class // ConfigValueProcessor is the 'MjrConfig', 'MnrConfigValue' error classification // for the issues with the value of processor. ConfigValueProcessor Class // ConfigValueFlag is the 'MjrConfig', 'MnrConfigValue' error classification // for the issues with the value of flag. ConfigValueFlag Class // ConfigValueNil is the 'MjrConfig', 'MnrConfigValue' error classification // for the issues related to the nil config value. ConfigValueNil Class // ConfigValueInvalid is the 'MjrConfig', 'MnrConfigValue' error classification // for config validation failures. ConfigValueInvalid Class )
var ( // MnrEncodingMarshal is the MnrEncodingMarshal Minor // EncodingMarshalOutputValue is the 'MjrEncoding', 'MnrEncodingMarshal' error classification // when the setting the output value. EncodingMarshalOutputValue Class // EncodingMarshalModelNotMapped is the 'MjrEncoding', 'MnrEncodingMarshal' error classification // when marshaling unmapped model. EncodingMarshalModelNotMapped Class // EncodingMarshalNilValue is the 'MjrEncoding', 'MnrEncodingMarshal' error classification // when the provided marshaling value is nil. EncodingMarshalNilValue Class // EncodingMarshalNonAddressable is the 'MjrEncoding', 'MnrEncodingMarshal' error classification // when the provided marshaling value is not addressable. EncodingMarshalNonAddressable Class // EncodingMarshalInput is the 'MjrEncoding', 'MnrEncodingMarshal' error classification // when the provided marshaling value is invalid. I.e. provided value is not a model structure. EncodingMarshalInput Class )
*
Encoding Marshal
var ( // MnrEncodingUnmarshal is the 'MjrEncoding' minor classification // for the unmarshall process. MnrEncodingUnmarshal Minor // EncodingUnmarshal is a 'MjrEncoding', 'MnrEncodingUnmarshal' error classification // for general purpose unmarshal errors. EncodingUnmarshal Class // EncodingUnmarshalCollection is a 'MjrEncoding', 'MnrEncodingUnmarshal' error classification // when unmarshaling the input data that has undefined model collection. EncodingUnmarshalCollection Class // EncodingUnmarshalFieldValue is a 'MjrEncoding', 'MnrEncodingUnmarshal' error classification // When unmarshaling field with invalid value. EncodingUnmarshalFieldValue Class // EncodingUnmarshalInvalidFormat is a 'MjrEncoding', 'MnrEncodingUnmarshal' error classification // while unmarshaling the input data has invalid format. I.e. invalid json formatting. EncodingUnmarshalInvalidFormat Class // EncodingUnmarshalInvalidID is a 'MjrEncoding', 'MnrEncodingUnmarshal' error classification // while unmarshaling the document with invalid primary field format or value. EncodingUnmarshalInvalidID Class // EncodingUnmarshalInvalidOutput is a 'MjrEncoding', 'MnrEncodingUnmarshal' error classification // while unmarshaling the document with invalid output model or slice. EncodingUnmarshalInvalidOutput Class // EncodingUnmarshalInvalidTime is a 'MjrEncoding', 'MnrEncodingUnmarshal' error classification // when unmarshaling time defined field with invalid type or value. EncodingUnmarshalInvalidTime Class // EncodingUnmarshalInvalidType is a 'MjrEncoding', 'MnrEncodingUnmarshal' error classification // while unmarshaling field with invalid value type. EncodingUnmarshalInvalidType Class // EncodingUnmarshalNoData is a 'MjrEncoding', 'MnrEncodingUnmarshal' error classification // while unmarshaling the empty data, when it is not allowed. EncodingUnmarshalNoData Class // EncodingUnmarshalUnknownField is a 'MjrEncoding', 'MnrEncodingUnmarshal' error classification // when trying to unmarshal undefined or unknown field. Used when 'strict' mode is set. EncodingUnmarshalUnknownField Class // EncodingUnmarshalValueOutOfRange is a 'MjrEncoding', 'MnrEncodingUnmarshal' error classification // when trying to unmarshal value with some range that exceeds defined maximum. EncodingUnmarshalValueOutOfRange Class )
var ( // MnrInternalQuery is the 'MjrInternal' minor classification for the internal // query errors. MnrInternalQuery Minor // InternalQueryNoStoredValue is the 'MjrInternal', 'MnrInternalQuery' error classification // for queries with no or invalid internal context values. InternalQueryNoStoredValue Class // InternalQueryIncluded is the 'MjrInternal', 'MnrInternalQuery' error classification // for the internal included fields issues. InternalQueryIncluded Class // InternalQueryInvalidField is the 'MjrInternal', 'MnrInternalQuery' error classification // for queries with invalid fields. InternalQueryInvalidField Class // InternalQueryNoSuchModel is the 'MjrInternal', 'MnrInternalQuery' error classification // when the model is not found for internal query operations. InternalQueryNoSuchModel Class // InternalQueryNilValue is the 'MjrInternal', 'MnrInternalQuery' error classification // when the internal query operations contains nil value. InternalQueryNilValue Class // InternalQuerySort is the 'MjrInternal', 'MnrInternalQuery' error classification // for invalid query sort fields. InternalQuerySort Class // InternalQueryFilter is the 'MjrInternal', 'MnrInternalQuery' error classification // for invalid internal query filter errors. InternalQueryFilter Class // InternalQuerySelectedField is the 'MjrInternal', 'MnrInternalQuery' error classification // for internal errors related with query selected fields. InternalQuerySelectedField Class // InternalQueryModelMismatch is the 'MjrInternal', 'MnrInternalQuery' error classification // for internal errors related with model type mismatch within internal methods. InternalQueryModelMismatch Class // InternalQueryValidation is the 'MjrInternal', 'MnrInternalQuery' error classification // for internal errors related with query validator. InternalQueryValidation Class // InternalQueryCardinality is the 'MjrQuery', 'MnrQueryViolation' error classifcation // when the provided query violates the query cardinality. InternalQueryCardinality Class // i.e. SELECT * FROM collection WHERE id IN (SELECT too,many,fields FROM other) )
*
Internal Query
var ( // MnrInternalEncoding is the 'MjrInternal' minor error classification // for internal encoding errors. MnrInternalEncoding Minor // InternalEncodingModelFieldType is the 'MjrInternal' 'MnrInternalEncoding' error classification // for internal encoding errors when the model field type is invalid. InternalEncodingModelFieldType Class // InternalEncodingValue is the 'MjrInternal' 'MnrInternalEncoding' error classification // for internal encoding errors with invalid value type. InternalEncodingValue Class // InternalEncodingPayload is the 'MjrInternal' 'MnrInternalEncoding' error classification // for internal encoding errors with some payload errors. InternalEncodingPayload Class // InternalEncodingIncludeScope is the 'MjrInternal' 'MnrInternalEncoding' error classification // for internal encoding errors with included scopes. InternalEncodingIncludeScope Class // InternalEncodingUnsupportedID is the 'MjrInternal' 'MnrInternalEncoding' error classification // for internal encoding errors with invalid primary field type or value. InternalEncodingUnsupportedID Class )
var ( // MnrInternalModel is the 'MjrInternal' minor error classifcation // for internal model issues. MnrInternalModel Minor // InternalModelRelationNotMapped is the 'MjrInternal', 'MnrInternalModel' error classification // for internal not mapped model relationships issues. InternalModelRelationNotMapped Class // InternalModelNotCast is the 'MjrInternal', 'MnrInternalModel' error classification // for the internal model's that should cast to some interface. InternalModelNotCast Class )
*
Internal Model
var ( // MnrInternalRepository is the 'MjrInternal' minor error classification // for the repository related internal issues. MnrInternalRepository Minor // InternalRepository is the 'MjrInternal', 'MnrInternalRepository' error classification // for internal repositories errors. InternalRepository Class // InternalRepositoryResourceName is the 'MjrInternal', 'MnrInternalRepository' error classification // for the errors related with the internal repository invalid resource name. InternalRepositoryResourceName Class // InternalRepositorySyntax is the 'MjrInternal', 'MnrInternalRepository' error classification // for the errors related with the internal repository syntax. InternalRepositorySyntax Class // InternalRepositorySystemError is the 'MjrInternal', 'MnrInternalRepository' error classification // while repository system error occurred: i.e. not enough disk space. InternalRepositorySystemError Class // InternalRepositoryClientMismatch is the 'MjrInternal', 'MnrInternalRepository' error classification // for internal errors on matching the repository clients. InternalRepositoryClientMismatch Class // InternalRepositoryIndex is the 'MjrInternal', 'MnrInternalRepository' error classification // for internal errors with index. InternalRepositoryIndex Class // InternalRepositoryOptions is the 'MjrInternal', 'MnrInternalRepository' error classification // for internal repository options errors. InternalRepositoryOptions Class )
*
Internal Repository
var ( // MnrInternalCommon is the common 'MjrInternal' minor error classification // for the non classified internal errors. MnrInternalCommon Minor // InternalCommon is the 'MjrInternal', 'MinorInternalCommon' error classification // for non classified internal errors. InternalCommon Class )
var ( // MnrLanguageUnsupported is the 'MjrLanguage' minor error classification // for unsupported langauges. MnrLanguageUnsupported Minor // LanguageUnsupportedTag is the 'MjrLanguage', 'MnrLanguageUnsupported' error // classification for unsupported language tags. LanguageUnsupportedTag Class // MnrLanguageParsing is the 'MjrLanguage' minor error classification for // parsing the languages issues. MnrLanguageParsing Minor // LanguageParsingFailed is the error classification when parsing language failed. LanguageParsingFailed Class )
var ( // MnrModelField is the 'MjrModel' minor error classification // on the model field's definitions. MnrModelField Minor // ModelFieldForeignKeyNotFound is the 'MjrModel', 'MnrModelField' error classification // when the model field's foreign key is not found issue. ModelFieldForeignKeyNotFound Class // ModelFieldName is the 'MjrModel', 'MnrModelField' error classification // on the model field's name issue. ModelFieldName Class // ModelFieldNestedType is the 'MjrModel', 'MnrModelField' error classification // on the model field's nested field type issue. ModelFieldNestedType Class // ModelFieldNotFound is the 'MjrModel', 'MnrModelField' error classification // when the model field is not found issue. ModelFieldNotFound Class // ModelFieldTag is the 'MjrModel', 'MnrModelField' error classification // on the model field's tag issue. ModelFieldTag Class // ModelFieldType is the 'MjrModel', 'MnrModelField' error classification // on the model field's type issue. ModelFieldType Class )
*
Model Field
var ( // MnrModelSchema is the 'MjrModel' minor error classification // on the model's schema issues. MnrModelSchema Minor // ModelInSchemaAlreadyRegistered is the 'MjrModel', 'MnrModelSchema' error classifcation // when the model is already registered within given schema. ModelInSchemaAlreadyRegistered Class // ModelSchemaNotFound is the 'MjrModel', 'MnrModelSchema' error classification // used when the model schema is not found. ModelSchemaNotFound Class // ModelNotMapped is the 'MjrModel', 'MnrModelSchema' error classification // used when the model is not mapped within schema. ModelNotMappedInSchema Class )
*
Model Schema
var ( // MnrModelRelationship is the 'MjrModel' minor error classification // on the issues with model relationships. MnrModelRelationship Minor // ModelRelationshipType is the 'MjrModel', 'MnrModelRelationship' error classification // on the issues with relationship's type. ModelRelationshipType Class // ModelRelationshipForeign is the 'MjrModel', 'MnrModelRelationship' error classification // on the issues with relationship's invalid foreign key. ModelRelationshipForeign Class // ModelRelationshipJoinModel is the 'MjrModel', 'MnrModelRelationship' error classification // on the issues with relationship's join model. ModelRelationshipJoinModel Class // ModelRelationshipBackreference is the 'MjrModel', 'MnrModelRelationship' error classification // on the issues with relationship's back reference field. ModelRelationshipBackreference Class // ModelRelationshipOptions is the 'MjrModel', 'MnrModelRelationship' error classification // on the issues with relationship options like: 'on error', 'on patch', 'on delete'. ModelRelationshipOptions Class )
*
Model Relationship
var ( // MnrModelValue is the 'MjrModel' minor error classification used for model value issues. MnrModelValue Minor // ModelValueNil is the 'MjrModel', 'MnrModelValue' error classification // for nil model values - while getting the model struct. ModelValueNil Class )
var ( // MnrModelMapping is the 'MjrModel' minor error classification for model mapping issues. MnrModelMapping Minor // ModelMappingNoFields is the 'MjrModel', 'MnrModelMapping' error classification // for model without required field or no fields at all. ModelMappingNoFields Class // ModelMappingInvalidType is the 'MjrModel', 'MnrModelMapping' error classification // for invalid types (i.e. field). ModelMappingInvalidType Class // ModelNotMapped is the 'MjrModel', 'MnrModelSchema' error classification // used when the model is not mapped within schema. ModelNotMapped Class )
var ( // MnrQueryFieldset is the 'MjrQuery' minor error classification // for query fieldset related issues. MnrQueryFieldset Minor // QueryFieldsetTooBig is the 'MjrQuery', 'MnrQueryFieldset' error classification // used when provided more than possible fields in the fieldset. QueryFieldsetTooBig Class // QueryFieldsetUnknownField is the 'MjrQuery', 'MnrQueryFieldset' error classificatio // used when the provided fieldset field is not found within the model's collection. QueryFieldsetUnknownField Class // QueryFieldsetDuplicate is the 'MjrQuery', 'MnrQueryFieldset' error classificatio // for duplicated fieldset field's name. QueryFieldsetDuplicate Class // QueryFieldsetInvalid is the 'MjrQuery', 'MnrQueryFieldset' error classification // for invalid fieldset issues. QueryFieldsetInvalid Class // QueryFieldsetEmpty is the 'MjrQuery', 'MnrQueryFieldset' error classification // for empty fieldset issues. QueryFieldsetEmpty Class )
var ( // MnrQuerySelectedFields is the 'MjrQuery' minor error classifcation // for the selected fields issues. MnrQuerySelectedFields Minor // QuerySelectedFieldsNotFound is the 'MjrQuery', 'MnrQuerySelectedFields' error classifcation // when the selected fields is not found. QuerySelectedFieldsNotFound Class // QuerySelectedFieldsNotSelected is the 'MjrQuery', 'MnrQuerySelectedFields' error classifcation // when unselecting fields which were not selected. QuerySelectedFieldsNotSelected Class // QuerySelectedFieldsInvalidModel is the 'MjrQuery', 'MnrQuerySelectedFields' error classification // when provided selected field is of invalid or non matched model. QuerySelectedFieldsInvalidModel Class // QuerySelectedFieldInvalid is the 'MjrQuery', 'MnrQuerySelectedFields' error classification // when the selected field is not valid. QuerySelectedFieldInvalid Class // QuerySelectedFieldAlreadyUsed is the 'MjrQuery', 'MnrQuerySelectedFields' error classification // whenthe selected field is already 'selected'. QuerySelectedFieldAlreadyUsed Class )
var ( // MnrQueryFilter is the 'MjrQuery' minor that classifies errors related with the query filters. MnrQueryFilter Minor // QueryFilterInvalidField is the 'MjrQuery', 'MnrQueryFilter' error classification // for invalid query filters field - name. QueryFilterInvalidField Class // QueryFilterInvalidFormat is the 'MjrQuery', 'MnrQueryFilter' error classification // for invalid query filter format. QueryFilterInvalidFormat Class // QueryFilterLanguage is the 'MjrQuery', 'MnrQueryFilter' error classification // for invalid query language filter. . QueryFilterLanguage Class // QueryFilterMissingRequired is the 'MjrQuery', 'MnrQueryFilter' error classification // for missing query filters. QueryFilterMissingRequired Class // QueryFilterUnknownCollection is the 'MjrQuery', 'MnrQueryFilter' error classification // for unknown query filter collection provided. QueryFilterUnknownCollection Class // QueryFilterUnknownField is the 'MjrQuery', 'MnrQueryFilter' error classification // for unknown query filter field. QueryFilterUnknownField Class // QueryFilterUnknownOperator is the 'MjrQuery', 'MnrQueryFilter' error classification // for unknown - invalid filter operator. QueryFilterUnknownOperator Class // QueryFilterUnsupportedField is the 'MjrQuery', 'MnrQueryFilter' error classification // for unsupported field types. QueryFilterUnsupportedField Class // QueryFilterUnsupportedOperator is the 'MjrQuery', 'MnrQueryFilter' error classification // for unsupported query filter operator. QueryFilterUnsupportedOperator Class // QueryFilterValue is the 'MjrQuery', 'MnrQueryFilter' error classification // for invalid filter values. QueryFilterValue Class // QueryFitlerNonMatched is the 'MjrQuery', 'MnrQueryFilter' error classification // for non matched model structures or field structures to models. QueryFitlerNonMatched Class // QueryFilterFieldKind is the 'MjrQuery', 'MnrQueryFilter' error classification // for invalid, unknown or unsupported filter field kind. QueryFilterFieldKind Class )
var ( // MnrQuerySorts is the 'MjrQuery' minor that classifies errors related with the sorts. MnrQuerySorts Minor // QuerySortField is the 'MjrQuery', 'MnrQuerySorts' error classification // for unknown, unsupported fields. QuerySortField Class // QuerySortFormat is the 'MjrQuery', 'MnrQuerySorts' error classification // for invalid sorting format. QuerySortFormat Class // QuerySortTooManyFields is the 'MjrQuery', 'MnrQuerySorts' error classification // when too many sorting fields provided. QuerySortTooManyFields Class // QuerySortRelatedFields is the 'MjrQuery', 'MnrQuerySorts' error classification // for unsupported sorting by related fields. QuerySortRelatedFields Class )
var ( // MnrQueryPagination is the 'MjrQuery' minor that classifies errors related with the pagination. MnrQueryPagination Minor // QueryPaginationValue is the 'MjrQuery', 'MnrQueryPagination' error classification // for invalid pagination values. I.e. invalid limit, offset value. QueryPaginationValue Class // QueryPaginationType is the 'MjrQuery', 'MnrQueryPagination' error classification // for invalid pagination type provided. QueryPaginationType Class // QueryPaginationAlreadySet is the 'MjrQuery', 'MnrQueryPagination' error classification // while trying to add pagination when it is already set. QueryPaginationAlreadySet Class )
var ( // MnrQueryValue is the 'MjrQuery' minor that classifies errors related with the query values. MnrQueryValue Minor // QueryNoValue is the 'MjrQuery', 'MnrQueryValue' error classification // for queries with no values provided. QueryNoValue Class // QueryValueMissingRequired is the 'MjrQuery', 'MnrQueryValue' error classifcation // occurred on missing required field values. QueryValueMissingRequired Class // QueryValueNoResult is the 'MjrQuery', 'MnrQueryValue' error classifaction // when query returns no results. QueryValueNoResult Class // QueryValuePrimary is the 'MjrQuery', 'MnrQueryValue' error classification // for queries with invalid primary field value. QueryValuePrimary Class // QueryValueType is the 'MjrQuery', 'MnrQueryValue' error classification // for queries with invalid or unsupported value type provided. QueryValueType Class // QueryValueUnaddressable is the 'MjrQuery', 'MnrQueryValue' error classifcation // for queries with unadresable value type provided. QueryValueUnaddressable Class // QueryValueValidation is the 'MjrQuery', 'MnrQueryValue' error classifaction // for queries with non validated values - validator failed. QueryValueValidation Class )
var ( // MnrQueryInclude is the 'MjrQuery' minor error classifcation // for the query includes issues. MnrQueryInclude Minor // QueryIncludeTooMany is the 'MjrQuery', 'MnrQueryInclude' error classifcation // used on when provided too many includes or too deep included field. QueryIncludeTooMany Class // QueryNotIncluded is the 'MjrQuery', 'MnrQueryInclude' error classification // used when the provided query collection / model is not included. QueryNotIncluded Class )
var ( // MnrQueryTransaction is the 'MjrQuery' minor error classification that defines issues with the query transactions. MnrQueryTransaction Minor // QueryTxBegin is the 'MjrQuery', 'MnrQueryTransaction' error classifaction // for query tranasaction begins. QueryTxBegin Class // QueryTxAlreadyBegin is the 'MjrQuery', 'MnrQueryTransaction' error classifaction // when query transaction had already begin. QueryTxAlreadyBegin Class // QueryTxAlreadyResolved is the 'MjrQuery', 'MnrQueryTransaction' error classifaction // when query transaction had already resolved. QueryTxAlreadyResolved Class // QueryTxNotFound is the 'MjrQuery', 'MnrQueryTransaction' error classifaction // when query transaction transaction not found for given query. QueryTxNotFound Class // QueryTxRollback is the 'MjrQuery', 'MnrQueryTransaction' error classifaction // when query transaction with rollback issues. QueryTxRollback Class // QueryTxFailed is the 'MjrQuery', 'MnrQueryTransaction' error classifaction // when query transaction failed. QueryTxFailed Class // QueryTxUnknownState is the 'MjrQuery', 'MnrQueryTransaction' error classifaction // when query transaction state is unknown. QueryTxUnknownState Class // QueryTxUnknownIsolationLevel is the 'MjrQuery', 'MnrQueryTransaction' error classifaction // when query transaction isolation level is unknown. QueryTxUnknownIsolationLevel Class // QueryTxTermination is the 'MjrQuery', 'MnrQueryTransaction' error classifaction // when query transaction is invalidly terminated. QueryTxTermination Class // QueryTxLockTimeOut is the 'MjrQuery', 'MnrQueryTransaction' error classification // when query transaction lock had timed out. QueryTxLockTimeOut Class )
var ( // MnrQueryViolation is the 'MjrQuery' minor error classifaction // related with query violations. MnrQueryViolation Minor // QueryViolationIntegrityConstraint is the 'MjrQuery', 'MnrQueryViolation' error classifcation // when the query violates integrity constraint in example no foreign key exists for given insertion query. QueryViolationIntegrityConstraint Class // QueryViolationNotNull is the 'MjrQuery', 'MnrQueryViolation' error classifcation // when the not null restriction is violated by the given insertion, patching query. QueryViolationNotNull Class // QueryViolationForeignKey is the 'MjrQuery', 'MnrQueryViolation' error classifcation // when the foreign key is being violated. QueryViolationForeignKey Class // QueryViolationUnique is the 'MjrQuery', 'MnrQueryViolation' error classifcation // when the uniqueness of the field is being violated. I.e. user defined primary key is not unique. QueryViolationUnique Class // QueryViolationCheck is the 'MjrQuery', 'MnrQueryViolation' error classifcation // when the repository value check is violated. I.e. SQL Check value. QueryViolationCheck Class // QueryViolationDataType is the 'MjrQuery', 'MnrQueryViolation' error classifcation // when the inserted data type violates the allowed data types. QueryViolationDataType Class // QueryViolationRestrict is the 'MjrQuery', 'MnrQueryViolation' error classifcation // while doing restricted operation. I.e. SQL based repository with field marked as RESTRICT. QueryViolationRestrict Class )
var ( // MnrQueryProcessor is the 'MjrQuery' error classification related with // the issues with the processes and a processor. MnrQueryProcessor Minor // QueryProcessorNotFound is the 'MjrQuery', 'MnrQueryProcessor' error classification // for the query processes not found. QueryProcessorNotFound Class )
var ( // MnrQueryRelation is the 'MjrQuery' minor error classification related // with the issues while querying the relations. MnrQueryRelation Minor // QueryRelation is the 'MjrQuery', 'MnrQueryRelation' error classification // for general issues while querying the relations. QueryRelation Class // QueryRelationNotFound is the 'MjrQuery', 'MnrQueryRelations' error classification // used when the relation query instance is not found. QueryRelationNotFound Class )
var ( // for unavailable repository access. MnrRepositoryUnavailable Minor // when the repository has insufficitent system resources to run. RepositoryUnavailableInsufficientResources Class // when the repository reached program limit - i.e. tried to extract too many columns at once. RepositoryUnavailableProgramLimit Class // when the repository is actually shutting down. RepositoryUnavailableShutdown Class )
var ( // MnrRepositoryAuth is the 'MjrRepository' minor error classification // related with Authorization or Authentication issues. MnrRepositoryAuth Minor // RepositoryAuthPrivileges is the 'MjrRepository', 'MnrRepositoryAuth' error classification // for insufficient authorization privileges issues. RepositoryAuthPrivileges Class )
var ( // MnrRepositoryConnection is the 'MjrRepository' minor error classification // for the repository connection issues. MnrRepositoryConnection Minor // RepositoryConnection is the 'MjrRepository', 'MnrRepositoryConnection' // error classification related with repository connection. RepositoryConnection Class // RepositoryConnectionTimedOut is the 'MjrRepository', 'MnrRepositoryConnection' // error classification related with timed out connection. RepositoryConnectionTimedOut Class // RepositoryConnectionURI is the 'MjrRepository', 'MnrRepositoryConnection' error classification // related with invalid connection URI for the repository. RepositoryConnectionURI Class // RepositoryConnectionSSL is the 'MjrRepository', 'MnrRepositoryConnection' error classification // related with SSL for the repository connections. RepositoryConnectionSSL Class )
var ( // MnrRepositoryNotImplements is the 'MjrRepository' minor error classification // for the repository interfaces. MnrRepositoryNotImplements Minor // RepositoryNotImplementsTransactioner is the 'MjrRepository', 'MnrRepositoryInterface' error classification // for errors when the repository doesn't implement transactioner interfaces. RepositoryNotImplementsTransactioner Class // RepositoryNotImplementsCreator is the 'MjrRepository', 'MnrRepositoryInterface' error classification // for errors when the repository doesn't implement query.Creator interfaces. RepositoryNotImplementsCreator Class // RepositoryNotImplementsDeleter is the 'MjrRepository', 'MnrRepositoryInterface' error classification // for errors when the repository doesn't implement query.Deleter interfaces. RepositoryNotImplementsDeleter Class // RepositoryNotImplementsPatcher is the 'MjrRepository', 'MnrRepositoryInterface' error classification // for errors when the repository doesn't implement query.Patcher interfaces. RepositoryNotImplementsPatcher Class // RepositoryNotImplementsLister is the 'MjrRepository', 'MnrRepositoryInterface' error classification // for errors when the repository doesn't implement query.Lister interfaces. RepositoryNotImplementsLister Class // RepositoryNotImplementsGetter is the 'MjrRepository', 'MnrRepositoryInterface' error classification // for errors when the repository doesn't implement getter interfaces. RepositoryNotImplementsGetter Class )
var ( // MnrRepositoryNotFound is the 'MjrRepository' minor error classification // when the repository is not found. MnrRepositoryNotFound Minor // RepositoryNotFound is the 'MjrRepository', 'MnrRepositoryNotFound' errors classification // when the repository for model is not found. RepositoryNotFound Class )
var ( // MnrRepositoryFactory is the 'MjrRepository' minor error classification // for repository factories issues. MnrRepositoryFactory Minor // RepositoryFactoryNotFound is the 'MjrRepository', 'MnrRepositoryFactory' error classification // for not found repository factory. RepositoryFactoryNotFound Class // RepositoryFactoryAlreadyRegistered is the 'MjrRepository', 'MnrRepositoryFactory' error classification // for the factories that were already registered. RepositoryFactoryAlreadyRegistered Class )
var ( // MnrRepositoryConfig is the 'MjrRepository' error classification for repository configurations MnrRepositoryConfig Minor // RepositoryConfigAlreadyRegistered is the 'MjrRepository', 'MnrRepositoryConfig' error classification // for already registered repository configurations. RepositoryConfigAlreadyRegistered Class // RepositoryConfigInvalid is the 'MjrRepository', 'MnrRepositoryConfig' error classification // for invalid repository configuration. RepositoryConfigInvalid Class )
var ( // MnrRepositoryReplica is the 'MjrRepository' minor error classification // for replicas errors. MnrRepositoryReplica Minor // RepositoryReplicaSetNotFound is the 'MjrRepository', 'MnrRepositoryReplica' error classification // where replica set is not found. RepositoryReplicaSetNotFound Class // RepositoryReplicaShardNotFound is the 'MjrRepository', 'MnrRepositoryReplica' error classification // where replica shard is not found. RepositoryReplicaShardNotFound Class // RepositoryReplicaNodeNotFound is the 'MjrRepository', 'MnrRepositoryReplica' error classification // where replica shard is not found. RepositoryReplicaNodeNotFound Class // RepositoryReplica is the 'MjrRepository', 'MnrRepositoryReplica' error classification for repository replicas. RepositoryReplica Class )
Functions ¶
This section is empty.
Types ¶
type Class ¶
type Class uint32
Class is the neuron error classification model. it is composed of the major, minor and index subclassifications. Each subclassifaction is a different length number, where major is composed of 7, minor 10 and index of 15 bits. Example:
44205263 in a binary form is 00000010101000101000010011001111 which decomposes into: 0000001 - major (7 bit) - 1 0101000101 - minor (10 bit) - 10 000010011001111 - index (15 bit) - 1231
Major should be a global scope division like 'Repository', 'Marshaler', 'Controller' etc. Minor should divide the 'major' into subclasses like the Repository filter builders, marshaler - invalid field etc. Index is the most precise classification - i.e. Repository - filter builder - unsupported operator.
var ( // RepositoryModelReservedName is the 'MjrRepository', 'MnrRepositoryModel' error classification // for reserved names in the repositories. RepositoryModelReservedName Class // RepositoryModelTags is the 'MjrRepository', 'MnrRepositoryModel' error classification // for invalid repository specific field tags. RepositoryModelTags Class )
var RepositoryUnmappedError Class
RepositoryUnmappedError is the error 'MjrRepository' classification used for unmapped repository specific error classes, types or codes.
func MustNewMinorClass ¶
MustNewMinorClass creates new minor class for provided argument. If the minor value is not vlaid the function panics.
func NewClass ¶
NewClass gets new class from the provided 'minor' and 'index'. If any of the arguments is not valid or out of bands the function returns an error.
func NewMinorClass ¶
NewMinorClass gets the class from provided 'minor'. The function gets minor's major and gets the major/minor class.
func (Class) MjrMnrMasked ¶
MjrMnrMasked returns the class value masked by the major and minor value only.
type Index ¶
type Index struct {
// contains filtered or unexported fields
}
Index is a 4 digit lowest level error classification. It is the most precise division - i.e.: 'major' Repository
'minor' filter builder 'index' unsupported operator.
type Major ¶
type Major uint8
Major is a 7 bit top level error classification.
var MjrCommon Major
MjrCommon is the common major errors classification.
var MjrConfig Major
MjrConfig - major that classifies errors related with the config.
var MjrEncoding Major
MjrEncoding - major that classifies errors related with the 'jsonapi' encoding
var MjrInternal Major
MjrInternal is the major internal error classfication.
var MjrLanguage Major
MjrLanguage is the major language error classification
var MjrModel Major
MjrModel - major that classifies errors related with the models mapping.
var MjrQuery Major
MjrQuery - major that classifies all the errors related with creating, operating on or changing the queries.
var MjrRepository Major
MjrRepository is the major error classification related with the repositories.
func MustRegisterMajor ¶
MustRegisterMajor regsiters new major error classification with provided 'name' and optional 'description' for the major. Panics when the major already exists.
func RegisterMajor ¶
RegisterMajor registers new major error classification with provided 'name', and optional 'description' for the major. Returns an error if there are already a maximum number of the Major's which is maximum uint8 value - 0xff.
func (Major) Description ¶
Description gets the major registered description.
func (Major) MustRegisterMinor ¶
MustRegisterMinor registers the minor classification for given Major 'm', 'name' - unique name for given Major and optional 'description'. Panics when the major is invalid.
func (Major) RegisterMinor ¶
RegisterMinor registers the minor classification for given Major 'm', 'name' - unique name for given Major and optional 'description'. If the major is not valid - out of bands - function throws an error.
type Minor ¶
type Minor struct {
// contains filtered or unexported fields
}
Minor is a 3 digit mid level error classification.
var MnrRepositoryModel Minor
MnrRepositoryModel is the minor error classification for the repository model issues.
func (Minor) Description ¶
Description gets the minor's description.
func (Minor) MustRegisterIndex ¶
MustRegisterIndex registers and returns index for given minor value. Panics if the index name already exists or the minor is not valid.
func (Minor) RegisterIndex ¶
RegisterIndex registers the index for given Minor.