[#19] schema: Add native schema consts
All checks were successful
DCO action / DCO (pull_request) Successful in 1m4s
Tests and linters / Tests (1.21) (pull_request) Successful in 1m9s
Tests and linters / Tests (1.20) (pull_request) Successful in 1m27s
Tests and linters / Tests with -race (pull_request) Successful in 1m20s
Tests and linters / Staticcheck (pull_request) Successful in 1m28s
Tests and linters / Lint (pull_request) Successful in 2m9s

Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
Dmitrii Stepanov 2023-11-14 12:27:39 +03:00
parent b7645489d0
commit 38985e4ec8

41
schema/native/consts.go Normal file
View file

@ -0,0 +1,41 @@
package native
const (
MethodGetObject = "GetObject"
MethodPutObject = "PutObject"
MethodHeadObject = "HeadObject"
MethodDeleteObject = "DeleteObject"
MethodSearchObject = "SearchObject"
MethodRangeObject = "RangeObject"
MethodHashObject = "HashObject"
ResourceFormatNamespaceObjects = "native:object/%s/*"
ResourceFormatNamespaceContainerObjects = "native:object/%s/%s/*"
ResourceFormatNamespaceContainerObject = "native:object/%s/%s/%s"
ResourceFormatRootObjects = "native:object/root/*"
ResourceFormatRootContainerObjects = "native:object/root/%s/*"
ResourceFormatRootContainerObject = "native:object/root/%s/%s"
ResourceFormatAllObjects = "native:object/*"
ResourceFormatNamespaceContainer = "native:container/%s/%s"
ResourceFormatNamespaceContainers = "native:container/%s/*"
ResourceFormatRootContainer = "native:container/root/%s"
ResourceFormatRootContainers = "native:container/root/*"
ResourceFormatAllContainers = "native:container/*"
PropertyKeyActorPublicKey = "$Actor:publicKey"
PropertyKeyActorRole = "$Actor:role"
PropertyKeyObjectVersion = "$Object:version"
PropertyKeyObjectID = "$Object:objectID"
PropertyKeyObjectContainerID = "$Object:containerID"
PropertyKeyObjectOwnerID = "$Object:ownerID"
PropertyKeyObjectCreationEpoch = "$Object:creationEpoch"
PropertyKeyObjectPayloadLength = "$Object:payloadLength"
PropertyKeyObjectPayloadHash = "$Object:payloadHash"
PropertyKeyObjectType = "$Object:objectType"
PropertyKeyObjectHomomorphicHash = "$Object:homomorphicHash"
)