GC: const variables extended to include default container names (#886)
## Description Moves constants to a file and adds more source definitions and backgrounds to constants. <!-- Insert PR description--> ## Type of change <!--- Please check the type of change your PR introduces: ---> - [x] 🐹 Trivial/Minor ## Issue(s) <!-- Can reference multiple issues. Use one of the following "magic words" - "closes, fixes" to auto-close the Github issue. --> *closes #823<issue> ## Test Plan Const variables to be used in future PRs. No tests are available. <!-- How will this be tested prior to merging.--> - [ ] 💪 Manual - [ ] ⚡ Unit test - [ ] 💚 E2E
This commit is contained in:
parent
c4abcd24bc
commit
f39a14eda3
@ -31,7 +31,18 @@ const (
|
|||||||
// Default Folder Names
|
// Default Folder Names
|
||||||
//------------------------
|
//------------------------
|
||||||
// Mail Definitions: https://docs.microsoft.com/en-us/graph/api/resources/mailfolder?view=graph-rest-1.0
|
// Mail Definitions: https://docs.microsoft.com/en-us/graph/api/resources/mailfolder?view=graph-rest-1.0
|
||||||
|
|
||||||
|
// inbox and root
|
||||||
|
DefaultMailFolder = "Inbox"
|
||||||
|
rootFolderAlias = "msgfolderroot"
|
||||||
DefaultContactFolder = "Contacts"
|
DefaultContactFolder = "Contacts"
|
||||||
|
DefaultCalendar = "Calendar"
|
||||||
|
|
||||||
|
//---------------------
|
||||||
|
// Paging
|
||||||
|
//-----------------
|
||||||
|
// nextDataLink definition https://docs.microsoft.com/en-us/graph/paging
|
||||||
|
nextDataLink = "@odata.nextLink"
|
||||||
)
|
)
|
||||||
|
|
||||||
// descendable represents objects that implement msgraph-sdk-go/models.entityable
|
// descendable represents objects that implement msgraph-sdk-go/models.entityable
|
||||||
@ -47,3 +58,9 @@ type displayable interface {
|
|||||||
GetId() *string
|
GetId() *string
|
||||||
GetDisplayName() *string
|
GetDisplayName() *string
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// container is an interface that implements both the descendable and displayble interface.
|
||||||
|
type container interface {
|
||||||
|
descendable
|
||||||
|
displayable
|
||||||
|
}
|
||||||
|
|||||||
@ -12,19 +12,6 @@ import (
|
|||||||
"github.com/alcionai/corso/src/internal/path"
|
"github.com/alcionai/corso/src/internal/path"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
|
||||||
// rootFolderAlias is the per-user root container alias for the exchange email
|
|
||||||
// hierarchy.
|
|
||||||
rootFolderAlias = "msgfolderroot"
|
|
||||||
// nextDataLink is a random map key so we can iterate through delta results.
|
|
||||||
nextDataLink = "@odata.nextLink"
|
|
||||||
)
|
|
||||||
|
|
||||||
type container interface {
|
|
||||||
descendable
|
|
||||||
displayable
|
|
||||||
}
|
|
||||||
|
|
||||||
// cachedContainer is used for local unit tests but also makes it so that this
|
// cachedContainer is used for local unit tests but also makes it so that this
|
||||||
// code can be broken into generic- and service-specific chunks later on to
|
// code can be broken into generic- and service-specific chunks later on to
|
||||||
// reuse logic in IDToPath.
|
// reuse logic in IDToPath.
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user