org.modeshape.jcr.RepositoryConfiguration.getDefaultWorkspaceName()方法的使用及代码示例

x33g5p2x  于2022-01-29 转载在 其他  
字(3.6k)|赞(0)|评价(0)|浏览(57)

本文整理了Java中org.modeshape.jcr.RepositoryConfiguration.getDefaultWorkspaceName方法的一些代码示例,展示了RepositoryConfiguration.getDefaultWorkspaceName的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。RepositoryConfiguration.getDefaultWorkspaceName方法的具体详情如下:
包路径:org.modeshape.jcr.RepositoryConfiguration
类名称:RepositoryConfiguration
方法名:getDefaultWorkspaceName

RepositoryConfiguration.getDefaultWorkspaceName介绍

[英]Get the name of the workspace that should be used for sessions where the client does not specify the name of the workspace.
[中]获取客户端未指定工作区名称的会话应使用的工作区名称。

代码示例

代码示例来源:origin: ModeShape/modeshape

/**
 * Obtain all of the workspace names specified by this repository, including the {@link #getPredefinedWorkspaceNames()
 * predefined workspaces} and the {@link #getDefaultWorkspaceName() default workspace}. The result does <i>not</i> contain the
 * names of any dynamically-created workspaces (e.g., those not specified in the configuration).
 *
 * @return the set of all workspace names defined by the configuration; never null
 */
public Set<String> getAllWorkspaceNames() {
  Set<String> names = getPredefinedWorkspaceNames();
  names.add(getDefaultWorkspaceName());
  return names;
}

代码示例来源:origin: org.fcrepo/modeshape-jcr

/**
 * Obtain all of the workspace names specified by this repository, including the {@link #getPredefinedWorkspaceNames()
 * predefined workspaces} and the {@link #getDefaultWorkspaceName() default workspace}. The result does <i>not</i> contain the
 * names of any dynamically-created workspaces (e.g., those not specified in the configuration).
 *
 * @return the set of all workspace names defined by the configuration; never null
 */
public Set<String> getAllWorkspaceNames() {
  Set<String> names = getPredefinedWorkspaceNames();
  names.add(getDefaultWorkspaceName());
  return names;
}

代码示例来源:origin: ModeShape/modeshape

/**
 * Obtain the names of the workspaces that were listed as being predefined. This includes the name
 * {@link #getDefaultWorkspaceName() default workspace}.
 *
 * @return the set of predefined (non-system) workspace names; never null
 */
public Set<String> getPredefinedWorkspaceNames() {
  Set<String> names = new HashSet<String>();
  Document workspaces = doc.getDocument(FieldName.WORKSPACES);
  if (workspaces != null) {
    List<?> predefined = workspaces.getArray(FieldName.PREDEFINED);
    if (predefined != null) {
      for (Object value : predefined) {
        if (value instanceof String) names.add((String)value);
      }
    }
  }
  names.add(getDefaultWorkspaceName());
  return names;
}

代码示例来源:origin: org.fcrepo/modeshape-jcr

/**
 * Obtain the names of the workspaces that were listed as being predefined. This includes the name
 * {@link #getDefaultWorkspaceName() default workspace}.
 *
 * @return the set of predefined (non-system) workspace names; never null
 */
public Set<String> getPredefinedWorkspaceNames() {
  Set<String> names = new HashSet<String>();
  Document workspaces = doc.getDocument(FieldName.WORKSPACES);
  if (workspaces != null) {
    List<?> predefined = workspaces.getArray(FieldName.PREDEFINED);
    if (predefined != null) {
      for (Object value : predefined) {
        if (value instanceof String) names.add((String)value);
      }
    }
  }
  names.add(getDefaultWorkspaceName());
  return names;
}

代码示例来源:origin: org.fcrepo/modeshape-jcr

getName()));
if (configuration.getDefaultWorkspaceName().equals(name)) {
  throw new UnsupportedOperationException(JcrI18n.unableToDestroyDefaultWorkspaceInRepository.text(name, getName()));

代码示例来源:origin: ModeShape/modeshape

getName()));
if (configuration.getDefaultWorkspaceName().equals(name)) {
  throw new UnsupportedOperationException(JcrI18n.unableToDestroyDefaultWorkspaceInRepository.text(name, getName()));

代码示例来源:origin: org.fcrepo/modeshape-jcr

} else {
  this.defaultWorkspaceName = config.getDefaultWorkspaceName();

代码示例来源:origin: ModeShape/modeshape

} else {
  this.defaultWorkspaceName = config.getDefaultWorkspaceName();

相关文章

微信公众号

最新文章

更多