public abstract class BaseSystemNdi extends AbstractSystemNdi
| Modifier and Type | Field and Description |
|---|---|
static ReplaceString |
COMMENT_LINE_CONFIG_HEADER |
LOG, session| Constructor and Description |
|---|
BaseSystemNdi(net.thevpc.nuts.NutsSession session) |
| Modifier and Type | Method and Description |
|---|---|
PathInfo |
addFileLine(PathInfoType type,
net.thevpc.nuts.NutsId id,
Path filePath,
ReplaceString commentLine,
String contentToAdd,
ReplaceString header) |
PathInfo[] |
addScript(NdiScriptOptions options,
String[] all) |
protected int |
compareIconExtensions(String a,
String b) |
protected int |
compareIconPaths(String a,
String b) |
PathInfo[] |
createArtifactScript(NdiScriptOptions options) |
PathInfo[] |
createBootScripts(NdiScriptOptions options) |
protected abstract FreeDesktopEntryWriter |
createFreeDesktopEntryWriter() |
PathInfo[] |
createLaunchTermShortcut(net.thevpc.nuts.NutsDesktopIntegrationItem nutsDesktopIntegrationItem,
NdiScriptOptions options,
String fileName,
String name) |
PathInfo[] |
createLaunchTermShortcutGlobal(net.thevpc.nuts.NutsDesktopIntegrationItem nutsDesktopIntegrationItem,
NdiScriptOptions options) |
String |
createNutsEnvString(NdiScriptOptions options,
boolean updateEnv,
boolean updatePATH) |
protected abstract String |
createNutsScriptContent(net.thevpc.nuts.NutsId fnutsId,
NdiScriptOptions options) |
PathInfo[] |
createShortcut(net.thevpc.nuts.NutsDesktopIntegrationItem nutsDesktopIntegrationItem,
NdiScriptOptions options) |
PathInfo[] |
createShortcut(net.thevpc.nuts.NutsDesktopIntegrationItem nutsDesktopIntegrationItem,
net.thevpc.nuts.NutsId id,
String path,
FreeDesktopEntry.Group shortcut) |
String |
dblQte(String line) |
abstract String |
getBashrcName() |
Path |
getBinScriptFile(String name,
NdiScriptOptions options) |
abstract String |
getCallScriptCommand(String path,
String... args) |
protected abstract ReplaceString |
getCommentLineConfigHeader() |
protected String |
getDefaultIconPath() |
net.thevpc.nuts.NutsActionSupport |
getDesktopIntegrationSupport(net.thevpc.nuts.NutsDesktopIntegrationItem target) |
protected abstract String |
getExecFileName(String name) |
protected abstract String |
getExportCommand(String[] names) |
Path |
getNutsAppsFolder(String apiVersion,
String switchWorkspaceLocation) |
NdiScriptInfo |
getNutsEnv(NdiScriptOptions options) |
NdiScriptInfo |
getNutsInit(NdiScriptOptions options) |
NdiScriptInfo |
getNutsStart(NdiScriptOptions options) |
NdiScriptInfo |
getNutsTerm(NdiScriptOptions options) |
NdiScriptInfo |
getNutsTermInit(NdiScriptOptions options) |
String |
getPathVarSep() |
abstract String |
getSetVarCommand(String name,
String value) |
abstract String |
getSetVarStaticCommand(String name,
String value) |
protected abstract ReplaceString |
getShebanSh() |
Path |
getShortcutPath(NdiScriptOptions options) |
NdiScriptInfo |
getSysRC(NdiScriptOptions options) |
abstract String |
getTemplateName(String name) |
abstract boolean |
isComments(String line) |
boolean |
isNutsBootId(net.thevpc.nuts.NutsId nid) |
abstract boolean |
isShortcutFieldNameUserFriendly() |
net.thevpc.nuts.NutsWorkspaceBootConfig |
loadSwitchWorkspaceLocationConfig(String switchWorkspaceLocation) |
protected boolean |
matchCondition(net.thevpc.nuts.NutsActionSupportCondition createDesktop,
net.thevpc.nuts.NutsActionSupport desktopIntegrationSupport) |
String |
newlineString() |
void |
onPostGlobal(NdiScriptOptions options,
PathInfo[] updatedPaths) |
PathInfo |
removeFileCommented2Lines(PathInfoType type,
net.thevpc.nuts.NutsId id,
Path filePath,
String commentLine,
boolean force) |
void |
removeNutsScript(String id,
String switchWorkspaceLocation,
net.thevpc.nuts.NutsSession session) |
protected String |
resolveBestIcon(String... iconPaths) |
String |
resolveIcon(String iconPath,
net.thevpc.nuts.NutsId appId) |
protected int |
resolveIconExtensionPriority(String extension)
bigger is better
|
String |
resolveShortcutFileName(net.thevpc.nuts.NutsId id,
net.thevpc.nuts.NutsDescriptor descriptor,
String fileName,
String name) |
boolean |
saveFile(Path filePath,
String content,
boolean force) |
SimpleScriptBuilder |
scriptBuilderSimple(PathInfoType type,
net.thevpc.nuts.NutsId anyId,
NdiScriptOptions options) |
FromTemplateScriptBuilder |
scriptBuilderTemplate(String templateName,
PathInfoType type,
net.thevpc.nuts.NutsId anyId,
NdiScriptOptions options) |
String |
smpQte(String line) |
List<String> |
splitLines(String text) |
PathInfo[] |
switchWorkspace(NdiScriptOptions options) |
abstract String |
toCommentLine(String line) |
abstract String |
trimComments(String line) |
protected abstract String |
varRef(String v) |
getSessionpublic static final ReplaceString COMMENT_LINE_CONFIG_HEADER
public abstract String getBashrcName()
public NdiScriptInfo getSysRC(NdiScriptOptions options)
public NdiScriptInfo getNutsInit(NdiScriptOptions options)
public NdiScriptInfo getNutsTermInit(NdiScriptOptions options)
public FromTemplateScriptBuilder scriptBuilderTemplate(String templateName, PathInfoType type, net.thevpc.nuts.NutsId anyId, NdiScriptOptions options)
public SimpleScriptBuilder scriptBuilderSimple(PathInfoType type, net.thevpc.nuts.NutsId anyId, NdiScriptOptions options)
public NdiScriptInfo getNutsTerm(NdiScriptOptions options)
public NdiScriptInfo getNutsEnv(NdiScriptOptions options)
public NdiScriptInfo getNutsStart(NdiScriptOptions options)
public Path getBinScriptFile(String name, NdiScriptOptions options)
public abstract boolean isComments(String line)
protected abstract String createNutsScriptContent(net.thevpc.nuts.NutsId fnutsId, NdiScriptOptions options)
public PathInfo[] createArtifactScript(NdiScriptOptions options)
public void removeNutsScript(String id, String switchWorkspaceLocation, net.thevpc.nuts.NutsSession session)
public PathInfo[] switchWorkspace(NdiScriptOptions options)
public boolean isNutsBootId(net.thevpc.nuts.NutsId nid)
public PathInfo[] createBootScripts(NdiScriptOptions options)
public PathInfo[] addScript(NdiScriptOptions options, String[] all)
public net.thevpc.nuts.NutsActionSupport getDesktopIntegrationSupport(net.thevpc.nuts.NutsDesktopIntegrationItem target)
protected boolean matchCondition(net.thevpc.nuts.NutsActionSupportCondition createDesktop,
net.thevpc.nuts.NutsActionSupport desktopIntegrationSupport)
public void onPostGlobal(NdiScriptOptions options, PathInfo[] updatedPaths)
public String newlineString()
public net.thevpc.nuts.NutsWorkspaceBootConfig loadSwitchWorkspaceLocationConfig(String switchWorkspaceLocation)
public PathInfo addFileLine(PathInfoType type, net.thevpc.nuts.NutsId id, Path filePath, ReplaceString commentLine, String contentToAdd, ReplaceString header)
public PathInfo removeFileCommented2Lines(PathInfoType type, net.thevpc.nuts.NutsId id, Path filePath, String commentLine, boolean force)
protected abstract FreeDesktopEntryWriter createFreeDesktopEntryWriter()
public PathInfo[] createShortcut(net.thevpc.nuts.NutsDesktopIntegrationItem nutsDesktopIntegrationItem, net.thevpc.nuts.NutsId id, String path, FreeDesktopEntry.Group shortcut)
protected int resolveIconExtensionPriority(String extension)
extension - extensionpublic Path getShortcutPath(NdiScriptOptions options)
public PathInfo[] createShortcut(net.thevpc.nuts.NutsDesktopIntegrationItem nutsDesktopIntegrationItem, NdiScriptOptions options)
protected String getDefaultIconPath()
public PathInfo[] createLaunchTermShortcutGlobal(net.thevpc.nuts.NutsDesktopIntegrationItem nutsDesktopIntegrationItem, NdiScriptOptions options)
public abstract boolean isShortcutFieldNameUserFriendly()
public String resolveShortcutFileName(net.thevpc.nuts.NutsId id, net.thevpc.nuts.NutsDescriptor descriptor, String fileName, String name)
public PathInfo[] createLaunchTermShortcut(net.thevpc.nuts.NutsDesktopIntegrationItem nutsDesktopIntegrationItem, NdiScriptOptions options, String fileName, String name)
public String createNutsEnvString(NdiScriptOptions options, boolean updateEnv, boolean updatePATH)
protected abstract ReplaceString getShebanSh()
protected abstract ReplaceString getCommentLineConfigHeader()
public String getPathVarSep()
Copyright © 2021 vpc open source initiative. All rights reserved.