本文整理汇总了Java中org.openide.windows.TopComponent.PERSISTENCE_ONLY_OPENED属性的典型用法代码示例。如果您正苦于以下问题:Java TopComponent.PERSISTENCE_ONLY_OPENED属性的具体用法?Java TopComponent.PERSISTENCE_ONLY_OPENED怎么用?Java TopComponent.PERSISTENCE_ONLY_OPENED使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类org.openide.windows.TopComponent
的用法示例。
在下文中一共展示了TopComponent.PERSISTENCE_ONLY_OPENED属性的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createXmlMultiViewElement
@MultiViewElement.Registration(
mimeType=PUDataLoader.REQUIRED_MIME,
iconBase=ICON,
persistenceType=TopComponent.PERSISTENCE_ONLY_OPENED,
preferredID=PREFERRED_ID_SOURCE,
displayName="#CTL_SourceTabCaption",
position=2000
)
@Messages("CTL_SourceTabCaption=Source")
public static XmlMultiViewElement createXmlMultiViewElement(Lookup lookup) {
return new XmlMultiViewElement(lookup.lookup(XmlMultiViewDataObject.class));
}
示例2: createMultiViewEditorElement
@MultiViewElement.Registration(
displayName="#CTL_SourceTabCaption",
iconBase="org/apache/tools/ant/module/resources/AntIcon.gif",
persistenceType=TopComponent.PERSISTENCE_ONLY_OPENED,
preferredID="ant",
mimeType=MIME_TYPE,
position=1
)
@Messages("CTL_SourceTabCaption=&Source")
public static MultiViewEditorElement createMultiViewEditorElement(Lookup context) {
return new MultiViewEditorElement(context);
}
示例3: createXmlMultiViewElement
@MultiViewElement.Registration(
mimeType=HibernateRevengDataLoader.REQUIRED_MIME,
iconBase=ICON,
persistenceType=TopComponent.PERSISTENCE_ONLY_OPENED,
preferredID=VIEW_ID,
displayName="#CTL_SourceTabCaption",
position=1
)
@NbBundle.Messages("CTL_SourceTabCaption=Source")
public static MultiViewEditorElement createXmlMultiViewElement(Lookup lookup) {
return new MultiViewEditorElement(lookup);
}
示例4: createEditor
@Messages("Source=&Source")
@MultiViewElement.Registration(
displayName = "#Source",
iconBase = LayerUtil.LAYER_ICON,
mimeType = "text/x-netbeans-layer+xml",
persistenceType = TopComponent.PERSISTENCE_ONLY_OPENED,
preferredID = "source",
position = 1
)
public static MultiViewEditorElement createEditor(Lookup lkp) {
return new MultiViewEditorElement(lkp);
}
示例5: createMultiViewEditorElement
@Messages("Source=&Source")
@MultiViewElement.Registration(displayName = "#Source",
iconBase = "org/netbeans/modules/spring/beans/resources/spring.png",
persistenceType = TopComponent.PERSISTENCE_ONLY_OPENED,
mimeType = SpringConstants.CONFIG_MIME_TYPE,
preferredID = "spring.xml.config",
position = 1)
public static MultiViewEditorElement createMultiViewEditorElement(Lookup context) {
return new MultiViewEditorElement(context);
}
示例6: createMultiViewEditorElement
@MultiViewElement.Registration(
displayName="#CTL_SourceTabCaption",
iconBase=POM_ICON,
persistenceType=TopComponent.PERSISTENCE_ONLY_OPENED,
preferredID="maven.pom",
mimeType=Constants.POM_MIME_TYPE,
position=1
)
public static MultiViewEditorElement createMultiViewEditorElement(Lookup context) {
return new MultiViewEditorElement(context);
}
示例7: createSettingsMultiViewEditorElement
@MultiViewElement.Registration(
displayName="#CTL_SourceTabCaption",
iconBase=POM_ICON,
persistenceType=TopComponent.PERSISTENCE_ONLY_OPENED,
preferredID="xml.text",
mimeType=SETTINGS_MIME_TYPE,
position=1
)
public static MultiViewEditorElement createSettingsMultiViewEditorElement(Lookup context) { // #202900 workaround
return new MultiViewEditorElement(context);
}
示例8: createXmlMultiViewElement
@MultiViewElement.Registration(
mimeType=HibernateMappingDataLoader.REQUIRED_MIME,
iconBase=ICON,
persistenceType=TopComponent.PERSISTENCE_ONLY_OPENED,
preferredID=VIEW_ID,
displayName="#CTL_SourceTabCaption",
position=1
)
@NbBundle.Messages("CTL_SourceTabCaption=Source")
public static MultiViewEditorElement createXmlMultiViewElement(Lookup lookup) {
return new MultiViewEditorElement(lookup);
}
示例9: createTopComponentPersistentID
private String createTopComponentPersistentID (TopComponent tc, String preferredID) throws IOException {
String compName = preferredID != null ? preferredID : null;
// be prepared for null names, empty names and convert to filesystem friendly name
if ((compName == null) || (compName.length() == 0)) {
compName = DEFAULT_TC_NAME;
}
//Check if component id is not already present in cache of invalid ids
boolean isUsed = true;
String origName = compName;
compName = escape(compName);
String srcName = compName;
int i = 1;
synchronized(LOCK_IDS) {
while (isUsed) {
isUsed = false;
String uniqueName = FileUtil.findFreeFileName(
getComponentsLocalFolder(), srcName, "settings" // NOI18N
);
if (!srcName.equals(uniqueName) || globalIDSet.contains(uniqueName.toUpperCase(Locale.ENGLISH))) {
isUsed = true;
// #44293 - proper escaping to keep name synced with InstanceDataObject naming
srcName = escape(origName + "_" + i);
i++;
}
}
topComponent2IDMap.put(tc, srcName);
id2TopComponentMap.put(srcName, new PersistenceManager.TopComponentReference(tc,srcName));
globalIDSet.add(srcName.toUpperCase(Locale.ENGLISH));
if (persistenceType(tc) == TopComponent.PERSISTENCE_ONLY_OPENED) {
topComponentPersistentOnlyOpenedID.add(srcName);
}
}
return srcName;
}
示例10: createMultiViewEditorElement
@NbBundle.Messages("Source=&Source")
@MultiViewElement.Registration(
displayName="#Source",
iconBase="org/netbeans/modules/languages/yaml/yaml_files_16.png",
persistenceType=TopComponent.PERSISTENCE_ONLY_OPENED,
mimeType=YamlTokenId.YAML_MIME_TYPE,
preferredID="neon.source",
position=1
)
public static MultiViewEditorElement createMultiViewEditorElement(Lookup context) {
return new MultiViewEditorElement(context);
}
示例11: createMultiViewEditorElement
@Messages("Source=&Source")
@MultiViewElement.Registration(
displayName="#Source",
iconBase="org/netbeans/modules/javawebstart/resources/jnlp.gif",
persistenceType=TopComponent.PERSISTENCE_ONLY_OPENED,
mimeType=JnlpDataLoader.REQUIRED_MIME,
preferredID="jnlp.source",
position=1
)
public static MultiViewEditorElement createMultiViewEditorElement(Lookup context) {
return new MultiViewEditorElement(context);
}
示例12: createMultiViewDTDElement
@MultiViewElement.Registration(
displayName="org.netbeans.modules.xml.Bundle#CTL_SourceTabCaption",
iconBase="org/netbeans/modules/xml/resources/entObject.gif",
persistenceType=TopComponent.PERSISTENCE_ONLY_OPENED,
preferredID="entity.text",
mimeType=MIME_TYPE,
position=1
)
public static MultiViewEditorElement createMultiViewDTDElement(Lookup context) {
return new MultiViewEditorElement(context);
}
示例13: createMultiViewEditorElement
@Messages("Source=&Source")
@MultiViewElement.Registration(
displayName="#Source",
iconBase="org/netbeans/modules/languages/manifest/manifest_file_16.png",
persistenceType=TopComponent.PERSISTENCE_ONLY_OPENED,
mimeType=MfLanguageProvider.MIME_TYPE,
preferredID="manifest.source",
position=1
)
public static MultiViewEditorElement createMultiViewEditorElement(Lookup context) {
return new MultiViewEditorElement(context);
}
示例14: createMultiViewEditorElement
@MultiViewElement.Registration(
displayName="org.netbeans.modules.xml.Bundle#CTL_SourceTabCaption",
iconBase="org/netbeans/modules/xml/resources/xmlObject.gif",
persistenceType=TopComponent.PERSISTENCE_ONLY_OPENED,
preferredID="xml.text",
mimeType=MIME_PLAIN_XML,
position=1
)
public static MultiViewEditorElement createMultiViewEditorElement(Lookup context) {
return new MultiViewEditorElement(context);
}
示例15: createMultiViewEditorElement
@MultiViewElement.Registration(displayName = "#LBL_LESSEditorTab",
iconBase = "org/netbeans/modules/css/prep/cssprep.png",
persistenceType = TopComponent.PERSISTENCE_ONLY_OPENED,
preferredID = "less.source",
mimeType = "text/less",
position = 1)
public static MultiViewEditorElement createMultiViewEditorElement(Lookup context) {
return new MultiViewEditorElement(context);
}