Root WebDAV and HTTP resource for one organisation's admin site, the entry point through which that organisation's users, websites and other admin-domain resources are reached. One instance is created per organisation whenever its admin domain is resolved, and it is used both to render the browser-facing admin UI and as the root object exposed to GraalJS for that organisation. An organisation with no parent organisation is treated as a root account.

Group: Resources

Extends: OrganisationFolder

Implements: RootFolder


Properties

PropertyReturnsDescription
allGroupsList<Group>All groups defined directly on this organisation.
attributesMap<String,Object>A scratch map for stashing arbitrary values against this root folder, for the lifetime of the request or session that holds it. Created empty on first access.
branchBranchBranch this resource belongs to, required by the WebsiteBranchResource interface. A root folder is not part of a website branch, so this always returns null.
domainNameStringFully qualified admin domain name for this organisation, built from the organisation's admin domain segment and the server's primary domain.
emailAddressStringDefault "noreply" sender address used for system emails sent on behalf of this organisation, built from the organisation's org id and the server's primary domain.
externalUrlStringFully qualified base URL of this organisation's admin site, for example "https://acme.admin.example.com/".
formattedNameStringDisplay-formatted name of this organisation, for use in UI labels.
idStringIdentifier of this root folder, which is the organisation's org id.
nameStringResource name of this root folder within the WebDAV tree. Always the empty string, since a root folder has no name relative to its own domain.
photoHashStringHash used to build a cache-busting URL for this organisation's logo photo. Null if the organisation has no photo.
requiresHttpsbooleanWhether this organisation's admin site requires HTTPS. Reflects the organisation's own forceHttps setting, and defaults to false when that setting is not configured.
rootbooleanWhether this organisation is a top-level account, that is, it has no parent organisation.
usersFolderUsersFolderThe users folder for this organisation's admin site, lazily created and cached on first access.

Inherited from RootFolder

Properties

PropertyReturnsDescription
languagesList<Language>The languages configured for translation in this root folder, as reported by TranslationService.
orgDataOrgDataThe organisation-level data record associated with this root folder.
selectedLangCodeStringThe language code currently selected for the request, as determined by TranslationService.
selectedLanguageLanguageThe Language matching the currently selected language code, looked up from getLanguages.

Methods

findEntity(Profile user) · getOrgData() · getSelectedLangCode() · getSelectedLanguage() · getLanguages() · childOrg(long id) · childOrg(String orgId) · findOrgType(String name) · addOrgType(String orgId, String orgType) · createOrgType(String name, String title) · removeOrgType(String orgId, String orgType) · findWebsite(long id) · findWebsite(String name)

findEntity(Profile user)

Returns: PrincipalResource

Locates the resource representing the given profile - a user, group or organisation - within this folder.

ParameterDescription
userthe profile to find a resource for

getOrgData()

Returns: OrgData

The organisation-level data record associated with this root folder.

getSelectedLangCode()

Returns: String

The language code currently selected for the request, as determined by TranslationService.

getSelectedLanguage()

Returns: Language

The Language matching the currently selected language code, looked up from getLanguages.

getLanguages()

Returns: List<Language>

The languages configured for translation in this root folder, as reported by TranslationService.

childOrg(long id)

Returns: Organisation

Locates a descendant organisation of this root folder's organisation by its internal Kademi id.

ParameterDescription
idthe internal id of the organisation to find

childOrg(String orgId)

Returns: Organisation

Locates a descendant organisation of this root folder's organisation by its external org id.

ParameterDescription
orgIdthe external org id of the organisation to find

findOrgType(String name)

Returns: OrgType

Finds an org type with the given name, searching this root folder's organisation and then its ancestors.

ParameterDescription
namethe name of the org type to find

addOrgType(String orgId, String orgType)

Returns: void

Adds an existing org type to the organisation identified by orgId, a child of this root folder's organisation, and fires an indexed-item-updated event for it.

ParameterDescription
orgIdthe external org id of the organisation to update
orgTypethe name of the org type to add

createOrgType(String name, String title)

Returns: OrgType

Creates and persists a new org type on this root folder's organisation, and fires an indexed-item-updated event for it.

ParameterDescription
namethe name of the org type to create
titlethe display name for the new org type

removeOrgType(String orgId, String orgType)

Returns: void

Removes an org type from the organisation identified by orgId, a child of this root folder's organisation, and fires an indexed-item-updated event for it.

ParameterDescription
orgIdthe external org id of the organisation to update
orgTypethe name of the org type to remove

findWebsite(long id)

Returns: Website

Finds a website of this root folder's organisation by its internal id.

ParameterDescription
idthe internal id of the website to find

findWebsite(String name)

Returns: Website

Finds a website of this root folder's organisation by its name.

ParameterDescription
namethe name of the website to find

Methods

isRoot() · getUsersFolder() · getName() · getId() · getDomainName() · getPhotoHash() · getFormattedName() · findEntity(Profile u) · getAttributes() · getEmailAddress() · getExternalUrl() · externalUrl(String path) · getBranch() · getAllGroups() · findWebsiteRootFolder(String name) · isRequiresHttps()

isRoot()

Returns: boolean

Whether this organisation is a top-level account, that is, it has no parent organisation.

getUsersFolder()

Returns: UsersFolder

The users folder for this organisation's admin site, lazily created and cached on first access.

getName()

Returns: String

Resource name of this root folder within the WebDAV tree. Always the empty string, since a root folder has no name relative to its own domain.

getId()

Returns: String

Identifier of this root folder, which is the organisation's org id.

getDomainName()

Returns: String

Fully qualified admin domain name for this organisation, built from the organisation's admin domain segment and the server's primary domain.

getPhotoHash()

Returns: String

Hash used to build a cache-busting URL for this organisation's logo photo. Null if the organisation has no photo.

getFormattedName()

Returns: String

Display-formatted name of this organisation, for use in UI labels.

findEntity(Profile u)

Returns: PrincipalResource

Locates the resource representing the given profile, whether a user, group or organisation, within this organisation's admin site.

ParameterDescription
uthe profile to find a resource for

getAttributes()

Returns: Map<String,Object>

A scratch map for stashing arbitrary values against this root folder, for the lifetime of the request or session that holds it. Created empty on first access.

getEmailAddress()

Returns: String

Default "noreply" sender address used for system emails sent on behalf of this organisation, built from the organisation's org id and the server's primary domain.

getExternalUrl()

Returns: String

Fully qualified base URL of this organisation's admin site, for example "https://acme.admin.example.com/".

externalUrl(String path)

Returns: String

Builds a fully qualified URL for an optional path within this organisation's admin site. A path that is already fully qualified (starts with "http:" or "https:") is returned unchanged.

ParameterDescription
paththe path to append to the site's base URL, or null for the site's root URL

getBranch()

Returns: Branch

Branch this resource belongs to, required by the WebsiteBranchResource interface. A root folder is not part of a website branch, so this always returns null.

getAllGroups()

Returns: List<Group>

All groups defined directly on this organisation.

findWebsiteRootFolder(String name)

Returns: WebsiteRootFolder

Looks up the named website within this organisation and returns its root folder.

ParameterDescription
namethe website's name

isRequiresHttps()

Returns: boolean

Whether this organisation's admin site requires HTTPS. Reflects the organisation's own forceHttps setting, and defaults to false when that setting is not configured.

To get full access to the Kademi Hub existing customers can login here, or new customers can register here.