本文整理了Java中org.modeshape.schematic.document.Document.keySet()
方法的一些代码示例,展示了Document.keySet()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Document.keySet()
方法的具体详情如下:
包路径:org.modeshape.schematic.document.Document
类名称:Document
方法名:keySet
[英]Returns this object's fields' names
[中]返回此对象的字段名称
代码示例来源:origin: org.fcrepo/modeshape-jcr
/**
* Get the names of the indexes defined in this configuration.
*
* @return the index names; never null but possibly empty
* @see #getIndex(String)
* @see #getRawIndex(String)
*/
public Set<String> getIndexNames() {
if (indexes == null) return Collections.emptySet();
return indexes.keySet();
}
代码示例来源:origin: ModeShape/modeshape
/**
* Get the names of the indexes defined in this configuration.
*
* @return the index names; never null but possibly empty
* @see #getIndex(String)
* @see #getRawIndex(String)
*/
public Set<String> getIndexNames() {
if (indexes == null) return Collections.emptySet();
return indexes.keySet();
}
代码示例来源:origin: org.fcrepo/modeshape-jcr
@SuppressWarnings( "synthetic-access" )
private void parseInitialContent( Document initialContent ) {
for (String workspaceName : initialContent.keySet()) {
Object value = initialContent.get(workspaceName);
if (value == null) value = "";
if (!(value instanceof String)) {
LOGGER.warn(JcrI18n.invalidInitialContentValue, value.toString(), workspaceName);
} else {
String initialContentFilePath = ((String)value).trim();
if (FieldName.DEFAULT_INITIAL_CONTENT.equals(workspaceName)) {
defaultInitialContentFile = initialContentFilePath;
} else {
workspacesInitialContentFiles.put(workspaceName, initialContentFilePath);
}
}
}
}
代码示例来源:origin: ModeShape/modeshape
@SuppressWarnings( "synthetic-access" )
private void parseInitialContent( Document initialContent ) {
for (String workspaceName : initialContent.keySet()) {
Object value = initialContent.get(workspaceName);
if (value == null) value = "";
if (!(value instanceof String)) {
LOGGER.warn(JcrI18n.invalidInitialContentValue, value.toString(), workspaceName);
} else {
String initialContentFilePath = ((String)value).trim();
if (FieldName.DEFAULT_INITIAL_CONTENT.equals(workspaceName)) {
defaultInitialContentFile = initialContentFilePath;
} else {
workspacesInitialContentFiles.put(workspaceName, initialContentFilePath);
}
}
}
}
代码示例来源:origin: org.fcrepo/modeshape-jcr
public Set<NodeKey> getReferrers( Document document,
ReferenceType type ) {
// Get the properties container ...
Document referrers = document.getDocument(REFERRERS);
if (referrers == null) {
return new HashSet<NodeKey>();
}
// Get the NodeKeys in the respective arrays ...
Set<NodeKey> result = new HashSet<NodeKey>();
if (type != ReferenceType.WEAK) {
Document strong = referrers.getDocument(STRONG);
if (strong != null) {
for (String keyString : strong.keySet()) {
result.add(new NodeKey(keyString));
}
}
}
if (type != ReferenceType.STRONG) {
Document weak = referrers.getDocument(WEAK);
if (weak != null) {
for (String keyString : weak.keySet()) {
result.add(new NodeKey(keyString));
}
}
}
return result;
}
代码示例来源:origin: ModeShape/modeshape
Set<String> names = externalSources.keySet();
for (String name : names) {
代码示例来源:origin: ModeShape/modeshape
public Set<NodeKey> getReferrers( Document document,
ReferenceType type ) {
// Get the properties container ...
Document referrers = document.getDocument(REFERRERS);
if (referrers == null) {
return new HashSet<NodeKey>();
}
// Get the NodeKeys in the respective arrays ...
Set<NodeKey> result = new HashSet<NodeKey>();
if (type != ReferenceType.WEAK) {
Document strong = referrers.getDocument(STRONG);
if (strong != null) {
for (String keyString : strong.keySet()) {
result.add(new NodeKey(keyString));
}
}
}
if (type != ReferenceType.STRONG) {
Document weak = referrers.getDocument(WEAK);
if (weak != null) {
for (String keyString : weak.keySet()) {
result.add(new NodeKey(keyString));
}
}
}
return result;
}
代码示例来源:origin: org.fcrepo/modeshape-jcr
Set<String> names = externalSources.keySet();
for (String name : names) {
代码示例来源:origin: ModeShape/modeshape
public Map<NodeKey, Integer> getReferrerCounts( Document document,
ReferenceType type ) {
// Get the properties container ...
Document referrers = document.getDocument(REFERRERS);
if (referrers == null) {
return Collections.emptyMap();
}
// Get the NodeKeys in the respective arrays ...
Map<NodeKey, Integer> result = new HashMap<>();
if (type == ReferenceType.STRONG || type == ReferenceType.BOTH) {
Document strong = referrers.getDocument(STRONG);
if (strong != null) {
for (String keyString : strong.keySet()) {
result.put(new NodeKey(keyString), strong.getInteger(keyString));
}
}
}
if (type == ReferenceType.WEAK || type == ReferenceType.BOTH) {
Document weak = referrers.getDocument(WEAK);
if (weak != null) {
for (String keyString : weak.keySet()) {
result.put(new NodeKey(keyString), weak.getInteger(keyString));
}
}
}
return result;
}
代码示例来源:origin: org.fcrepo/modeshape-jcr
public Map<NodeKey, Integer> getReferrerCounts( Document document,
ReferenceType type ) {
// Get the properties container ...
Document referrers = document.getDocument(REFERRERS);
if (referrers == null) {
return Collections.emptyMap();
}
// Get the NodeKeys in the respective arrays ...
Map<NodeKey, Integer> result = new HashMap<>();
if (type == ReferenceType.STRONG || type == ReferenceType.BOTH) {
Document strong = referrers.getDocument(STRONG);
if (strong != null) {
for (String keyString : strong.keySet()) {
result.put(new NodeKey(keyString), strong.getInteger(keyString));
}
}
}
if (type == ReferenceType.WEAK || type == ReferenceType.BOTH) {
Document weak = referrers.getDocument(WEAK);
if (weak != null) {
for (String keyString : weak.keySet()) {
result.put(new NodeKey(keyString), weak.getInteger(keyString));
}
}
}
return result;
}
代码示例来源:origin: org.fcrepo/modeshape-jcr
for (String sourceName : externalSources.keySet()) {
Document externalSource = externalSources.getDocument(sourceName);
if (!externalSource.containsField(FieldName.PROJECTIONS)) {
代码示例来源:origin: ModeShape/modeshape
for (String sourceName : externalSources.keySet()) {
Document externalSource = externalSources.getDocument(sourceName);
if (!externalSource.containsField(FieldName.PROJECTIONS)) {
代码示例来源:origin: org.fcrepo/modeshape-jcr
for (String sourceName : binaryStoresConfiguration.keySet()) {
Document binaryStoreConfig = binaryStoresConfiguration.getDocument(sourceName);
binaryStores.put(sourceName, new BinaryStorage(binaryStoreConfig).getBinaryStore());
代码示例来源:origin: ModeShape/modeshape
for (String sourceName : binaryStoresConfiguration.keySet()) {
Document binaryStoreConfig = binaryStoresConfiguration.getDocument(sourceName);
binaryStores.put(sourceName, new BinaryStorage(binaryStoreConfig).getBinaryStore());
内容来源于网络,如有侵权,请联系作者删除!