public class KeepDbInfo
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
KeepDbInfo.FormulaEngine
Formula engine to use for calculating formulas.
|
Constructor and Description |
---|
KeepDbInfo(java.lang.String apiName,
java.lang.String path)
Standard constructor
|
Modifier and Type | Method and Description |
---|---|
KeepDbInfo |
addAvailableView(java.lang.String passedName,
java.lang.String passedUnid)
Addsa an available view to the list of views exposed.
|
KeepDbInfo |
copyFormModes(KeepDbInfo incoming)
Copies form modes from old to new configuration used when saving a new instance of the configuration
|
static KeepDbInfo |
fromDocument(com.hcl.domino.DominoClient client,
com.hcl.domino.data.Document doc) |
static KeepDbInfo |
fromJson(io.vertx.core.json.JsonObject source,
boolean suppressEmptyFieldWarning)
Initialize a KeepDbInfo object from a JSON object
|
java.util.Set<java.lang.String> |
getAgents()
Gets the list of Domino Agents in the database that can be triggered from Keep.
|
java.lang.String |
getApiName()
Gets Keep database name.
|
java.util.Set<java.lang.String> |
getAvailableViews()
Returns a list of available View names including aliases
|
long |
getCacheTimestamp() |
java.util.Set<java.lang.String> |
getConfiguredForms()
Gets forms configured for this Keep application
|
java.lang.String |
getDescription()
Gets a textual description for the database to be used in the admin interface.
|
boolean |
getDqlAccess()
Gets the formula for restricting access to DQL queries.
|
java.lang.String |
getDqlFormula() |
java.lang.String |
getDXLPath() |
static java.lang.String |
getDXLPath(java.lang.String incomingPath) |
java.lang.String |
getFilePath()
Filepath on Domino where the database is located.
|
java.util.List<java.lang.String> |
getFormAccessModes(java.lang.String formName)
Returns the Form Access Modes available for a specific form name
|
java.util.Map<java.lang.String,java.lang.String> |
getFormAliases()
Gets a Map of form alises, where the alias is the key and the actual form name is the value.
|
FormAccessModeInfo |
getFormConfig(java.lang.String formName,
java.lang.String modeName)
Gets a Form Access Mode configuration for a specific form name and mode name
|
java.util.Map<java.lang.String,FormAccessModeInfo> |
getFormConfigInfo(java.lang.String formName)
Gets all Form Access Mode configurations for a specific form name
|
java.util.Map<java.lang.String,java.util.Map<java.lang.String,FormAccessModeInfo>> |
getFormConfigs()
Gets Forms and their FormAccessMode configurations
|
KeepDbInfo.FormulaEngine |
getFormulaEngine()
Formula engine in use for applying formulas for access and onload / onsave events of Form modes.
|
java.lang.String |
getIcon()
Base64 encoded image to be used for the database icon.
|
java.lang.String |
getIconName()
Alt text for the icon image.
|
java.util.List<java.lang.String> |
getOwners()
List of people or groups who can administer this Keep database config
|
java.util.Set<java.lang.String> |
getStoredProcedures()
Gets the “stored procedures” or inline code that can be run against the database via Keep.
|
java.lang.String |
getUnid()
UniversalID of the document for this keep database config
|
java.lang.String |
getViewUnid(java.lang.String viewName) |
boolean |
hasViewRestrictions() |
boolean |
isAllowCode()
Gets whether
\/run\/code or \/run\/codejs endpoints can be used to run inline code against this database via Keep. |
boolean |
isAllowDecryption() |
boolean |
isIsActive()
Whether or not the keep database config is active for non-admin calls
|
boolean |
isOpenAccess()
Gets whether or not access to browser-based REST services are allowed.
|
void |
loadAdditionalContentFromDesign()
Loads form aliases from design
|
void |
loadAdditionalContentFromPassedDesign(io.vertx.core.json.JsonObject cacheResult) |
KeepDbInfo |
loadFormAccessModes(java.lang.String formName,
java.util.Map<java.lang.String,FormAccessModeInfo> formModeConfigs)
Merges the Form Access Mode configurations for a specific form name with the existing content, overwriting any found
|
KeepDbInfo |
loadOneFormAccessMode(java.lang.String formName,
java.lang.String modeName,
FormAccessModeInfo modeConfig)
Merges the Form Access Mode configuration for a specific form name and mode name with the existing content, overwriting any found
|
KeepDbInfo |
removeForm(java.lang.String formName)
Remove all Form Access Mode configurations for a specific form
|
KeepDbInfo |
removeFormAccessMode(java.lang.String formName,
java.lang.String modeName)
Remove an individual Form Access Mode configuration for a specific form and form access mode name
|
KeepDbInfo |
saveToDoc(KeepJnxSession session,
com.hcl.domino.data.Document doc,
KeepFactory factory)
Save content to to a note - including saveing the note
|
KeepDbInfo |
setAllowCode(boolean allowCode)
Sets whether
\/run\/code or \/run\/codejs endpoints can be used to run inline code against this database via Keep. |
KeepDbInfo |
setAllowDecryption(boolean allowDecryption) |
void |
setCacheTimestamp(long cacheTimestamp) |
KeepDbInfo |
setConfigInfoFromJson(io.vertx.core.json.JsonObject source)
Sets part of KeepDBInfo that is stored in one field in KeepConfig until resolved to store it in MIME
|
KeepDbInfo |
setDescription(java.lang.String description)
Sets a textual description for the database to be used in the admin interface.
|
KeepDbInfo |
setDqlAccess(boolean dqlAccess)
Sets the formula for restricting access to DQL queries, e.g.
|
KeepDbInfo |
setDqlFormula(java.lang.String dqlFormula) |
KeepDbInfo |
setFormAliases(java.util.Map<java.lang.String,java.lang.String> formAliases)
Loads a Map of form aliases and the actual form, for use when retrieving Form Access Modes against actual documents
|
KeepDbInfo |
setFormConfigs(java.util.Map<java.lang.String,java.util.Map<java.lang.String,FormAccessModeInfo>> formConfigs)
Loads Forms and their Form Access Mode configurations
|
KeepDbInfo |
setFormulaEngine(KeepDbInfo.FormulaEngine formulaEngine)
Sets the formula engine in use for applying formulas for access and onload / onsave events of Form modes.
|
KeepDbInfo |
setFormulaEngine(java.lang.String formulaEngineValue)
Using a string value, sets the formula engine in use for applying formulas for access and onload / onsave events of Form modes.
|
KeepDbInfo |
setIcon(java.lang.String icon)
Sets the image icon to be used for the database in Keep.
|
KeepDbInfo |
setIconName(java.lang.String iconName)
Sets the alt name for the icon image.
|
KeepDbInfo |
setIsActive(boolean isActive)
Sets the keep database configuration as active or inactive
|
KeepDbInfo |
setIsActive(java.lang.String isActive)
Sets the keep database configuration as active or inactive
|
KeepDbInfo |
setOpenAccess(boolean openAccess)
Sets whether or not access to browser-based REST services are allowed.
|
KeepDbInfo |
setOwners(io.vertx.core.json.JsonArray jsonOwners)
Sets the people or groups who can administer this Keep database config from a
JsonArray . |
KeepDbInfo |
setOwners(java.util.List<java.lang.String> owners)
Sets the people or groups who can administer this Keep database config.
|
KeepDbInfo |
setStoredProcedures(io.vertx.core.json.JsonArray jsonStoredProcedures)
Sets the “stored procedures” or inline code that can be run against the database via Keep.
|
KeepDbInfo |
setUnid(java.lang.String unid)
Sets the universalID of the document for this keep database config
|
io.vertx.core.json.JsonObject |
toJson() |
io.vertx.core.json.JsonObject |
toJsonComplete() |
public KeepDbInfo(java.lang.String apiName, java.lang.String path)
Standard constructor
apiName
- path
- public static KeepDbInfo fromDocument(com.hcl.domino.DominoClient client, com.hcl.domino.data.Document doc)
client
- Domino Client entry pointdoc
- public void loadAdditionalContentFromDesign()
Loads form aliases from design
public void loadAdditionalContentFromPassedDesign(io.vertx.core.json.JsonObject cacheResult)
cacheResult
- JsonObject corresponding to designpublic static KeepDbInfo fromJson(@Nonnull io.vertx.core.json.JsonObject source, boolean suppressEmptyFieldWarning)
Initialize a KeepDbInfo object from a JSON object
source
- suppressEmptyFieldWarning
- public static java.lang.String getDXLPath(@Nonnull java.lang.String incomingPath)
incomingPath
- public KeepDbInfo copyFormModes(KeepDbInfo incoming)
Copies form modes from old to new configuration used when saving a new instance of the configuration
incoming
- public java.util.Set<java.lang.String> getAgents()
Gets the list of Domino Agents in the database that can be triggered from Keep.
public java.lang.String getApiName()
Gets Keep database name. This will be the ?db
query parameter in calls. Only settable in constructors.
public java.util.Set<java.lang.String> getAvailableViews()
Returns a list of available View names including aliases
public java.util.Set<java.lang.String> getConfiguredForms()
Gets forms configured for this Keep application
public java.lang.String getDescription()
Gets a textual description for the database to be used in the admin interface.
public boolean getDqlAccess()
Gets the formula for restricting access to DQL queries. Keep Admins will always be able to run DQL, regardless of this setting.
public java.lang.String getDqlFormula()
public java.lang.String getDXLPath()
public java.lang.String getFilePath()
Filepath on Domino where the database is located. This is not designed to be exposed outside the internals of the Keep code. Only settable via the constructors.
public java.util.List<java.lang.String> getFormAccessModes(java.lang.String formName)
Returns the Form Access Modes available for a specific form name
formName
- to filter onpublic java.util.Map<java.lang.String,java.lang.String> getFormAliases()
Gets a Map of form alises, where the alias is the key and the actual form name is the value. This needs to be used to get the relevant Form Access Mode when processing a document.
public FormAccessModeInfo getFormConfig(@Nonnull java.lang.String formName, java.lang.String modeName)
Gets a Form Access Mode configuration for a specific form name and mode name
formName
- to filter onmodeName
- for the required formpublic java.util.Map<java.lang.String,FormAccessModeInfo> getFormConfigInfo(java.lang.String formName)
Gets all Form Access Mode configurations for a specific form name
formName
- to filter onpublic java.util.Map<java.lang.String,java.util.Map<java.lang.String,FormAccessModeInfo>> getFormConfigs()
Gets Forms and their FormAccessMode configurations
public KeepDbInfo.FormulaEngine getFormulaEngine()
Formula engine in use for applying formulas for access and onload / onsave events of Form modes.
public java.lang.String getIcon()
Base64 encoded image to be used for the database icon. Preferably svg for better resizing.
public java.lang.String getIconName()
Alt text for the icon image.
public java.util.List<java.lang.String> getOwners()
List of people or groups who can administer this Keep database config
public java.util.Set<java.lang.String> getStoredProcedures()
Gets the “stored procedures” or inline code that can be run against the database via Keep.
public java.lang.String getUnid()
UniversalID of the document for this keep database config
public java.lang.String getViewUnid(java.lang.String viewName)
viewName
- to look uppublic boolean hasViewRestrictions()
public boolean isAllowCode()
Gets whether \/run\/code
or \/run\/codejs
endpoints can be used to run inline code against this database via Keep. Keep Admins will always be able to run inline code, regardless of this setting.
public boolean isAllowDecryption()
public boolean isIsActive()
Whether or not the keep database config is active for non-admin calls
public boolean isOpenAccess()
Gets whether or not access to browser-based REST services are allowed. If not, access must go via an external application configuration, where all access will require an appId and appSecret.
public KeepDbInfo loadFormAccessModes(java.lang.String formName, java.util.Map<java.lang.String,FormAccessModeInfo> formModeConfigs)
Merges the Form Access Mode configurations for a specific form name with the existing content, overwriting any found
formName
- to add Form Access Mode configurations forformModeConfigs
- Map of Form Access Mode configurations to loadpublic KeepDbInfo loadOneFormAccessMode(java.lang.String formName, java.lang.String modeName, FormAccessModeInfo modeConfig)
Merges the Form Access Mode configuration for a specific form name and mode name with the existing content, overwriting any found
formName
- to add Form Access Mode configurations formodeName
- to load formodeConfig
- Form Access Mode configuration to loadpublic KeepDbInfo removeForm(java.lang.String formName)
Remove all Form Access Mode configurations for a specific form
formName
- to removepublic KeepDbInfo removeFormAccessMode(java.lang.String formName, java.lang.String modeName) throws KeepException
Remove an individual Form Access Mode configuration for a specific form and form access mode name
formName
- to filter onmodeName
- to removeKeepException
- for bad requestsKeepExceptionNotFound
- for form names not foundpublic KeepDbInfo saveToDoc(KeepJnxSession session, com.hcl.domino.data.Document doc, KeepFactory factory) throws KeepException, java.io.IOException
Save content to to a note - including saveing the note
session
- doc
- factory
- KeepException
java.io.IOException
public KeepDbInfo setAllowCode(boolean allowCode)
Sets whether \/run\/code
or \/run\/codejs
endpoints can be used to run inline code against this database via Keep.
allowCode
- whether code endpoints are allowedpublic KeepDbInfo setAllowDecryption(boolean allowDecryption)
allowDecryption
- the allowDecryption to setpublic KeepDbInfo setConfigInfoFromJson(io.vertx.core.json.JsonObject source)
Sets part of KeepDBInfo that is stored in one field in KeepConfig until resolved to store it in MIME
source
- JsonObjectpublic KeepDbInfo setDescription(java.lang.String description)
Sets a textual description for the database to be used in the admin interface.
description
- for the databasepublic KeepDbInfo setDqlAccess(boolean dqlAccess)
Sets the formula for restricting access to DQL queries, e.g.
@IsMember("[Admin]";@UserRoles);
Result: Only users with Admin role (and Keep Administrators) can run custom DQL queries.
dqlAccess
- formula to applypublic KeepDbInfo setDqlFormula(java.lang.String dqlFormula)
dqlFormula
- the dqlFormula to setpublic KeepDbInfo setFormAliases(java.util.Map<java.lang.String,java.lang.String> formAliases)
Loads a Map of form aliases and the actual form, for use when retrieving Form Access Modes against actual documents
formAliases
- map of alias and actual form namepublic KeepDbInfo setFormConfigs(java.util.Map<java.lang.String,java.util.Map<java.lang.String,FormAccessModeInfo>> formConfigs)
Loads Forms and their Form Access Mode configurations
formConfigs
- Map of maps, where the keys for the first Map is the Form name and the key for the inner map is the mode namepublic KeepDbInfo setFormulaEngine(KeepDbInfo.FormulaEngine formulaEngine)
Sets the formula engine in use for applying formulas for access and onload / onsave events of Form modes.
formulaEngine
- enumpublic KeepDbInfo setFormulaEngine(java.lang.String formulaEngineValue)
Using a string value, sets the formula engine in use for applying formulas for access and onload / onsave events of Form modes.
formulaEngineValue
- as stringpublic KeepDbInfo setIcon(java.lang.String icon)
Sets the image icon to be used for the database in Keep.
icon
- Base64 encoded string image, preferably svg for better resizing.public KeepDbInfo setIconName(java.lang.String iconName)
Sets the alt name for the icon image.
iconName
- the iconName to setpublic KeepDbInfo setIsActive(boolean isActive)
Sets the keep database configuration as active or inactive
isActive
- for data callspublic KeepDbInfo setIsActive(java.lang.String isActive)
Sets the keep database configuration as active or inactive
isActive
- “isActive” for true, anything else for falsepublic KeepDbInfo setOpenAccess(boolean openAccess)
Sets whether or not access to browser-based REST services are allowed. If not, access must go via an external application configuration, where all access will require an appId and appSecret.
openAccess
- whether browser-based access is permittedpublic KeepDbInfo setOwners(io.vertx.core.json.JsonArray jsonOwners)
Sets the people or groups who can administer this Keep database config from a JsonArray
.
jsonOwners
- array of administrators for this Keep database configurationpublic KeepDbInfo setOwners(java.util.List<java.lang.String> owners)
Sets the people or groups who can administer this Keep database config.
owners
- administrators for this Keep database configurationpublic KeepDbInfo setStoredProcedures(io.vertx.core.json.JsonArray jsonStoredProcedures)
Sets the “stored procedures” or inline code that can be run against the database via Keep.
jsonStoredProcedures
- set of stored procedurespublic KeepDbInfo setUnid(java.lang.String unid)
Sets the universalID of the document for this keep database config
unid
- 32-character hex stringpublic KeepDbInfo addAvailableView(java.lang.String passedName, java.lang.String passedUnid)
Addsa an available view to the list of views exposed. Used when creating a view programmatically
passedName
- view namepassedUnid
- UNID of the view design elementpublic io.vertx.core.json.JsonObject toJson()
public io.vertx.core.json.JsonObject toJsonComplete()
public long getCacheTimestamp()
public void setCacheTimestamp(long cacheTimestamp)
cacheTimestamp
- timestamp for when design data was last added