public class DefaultNSession extends Object implements Cloneable, NSession, NCopiable
| Modifier and Type | Field and Description |
|---|---|
static InheritableThreadLocal<Stack<NSession>> |
CURRENT_SESSION |
protected List<String> |
outputFormatOptions |
protected NWorkspace |
workspace |
| Constructor and Description |
|---|
DefaultNSession(NWorkspace workspace) |
DefaultNSession(NWorkspace workspace,
NWorkspaceOptions options) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitconfigure, configure, configureLastpublic static final InheritableThreadLocal<Stack<NSession>> CURRENT_SESSION
protected NWorkspace workspace
public DefaultNSession(NWorkspace workspace)
public DefaultNSession(NWorkspace workspace, NWorkspaceOptions options)
public void close()
public final NSession configure(boolean skipUnsupported, String... args)
NCmdLineConfigurable.configure(boolean, java.lang.String...)
to help return a more specific return type;configure in interface NCmdLineConfigurableargs - argument to configure withthis instancepublic boolean configureFirst(NCmdLine cmdLine)
configureFirst in interface NCmdLineConfigurablepublic boolean isPlainTrace()
isPlainTrace in interface NSessionpublic boolean isIterableTrace()
isIterableTrace in interface NSessionpublic boolean isStructuredTrace()
isStructuredTrace in interface NSessionpublic boolean isIterableOut()
isIterableOut in interface NSessionpublic NSession setIterableOut(boolean iterableOut)
setIterableOut in interface NSessionpublic boolean isStructuredOut()
isStructuredOut in interface NSessionpublic NArrayElementBuilder getElemOut()
getElemOut in interface NSessionpublic NSession setElemOut(NArrayElementBuilder eout)
setElemOut in interface NSessionpublic boolean isPlainOut()
isPlainOut in interface NSessionpublic NOptional<Boolean> getPreviewRepo()
getPreviewRepo in interface NSessionpublic boolean isPreviewRepo()
isPreviewRepo in interface NSessionpublic NSession setPreviewRepo(Boolean bot)
setPreviewRepo in interface NSessionpublic NOptional<NContentType> getOutputFormat()
getOutputFormat in interface NSessionpublic NSession setOutputFormat(NContentType outputFormat)
setOutputFormat in interface NSessionpublic NSession copy()
public NSession copyFrom(NWorkspaceOptions options)
public NSession copyFrom(NBootOptions options)
public NOptional<NFetchStrategy> getFetchStrategy()
getFetchStrategy in interface NSessionpublic NSession setFetchStrategy(NFetchStrategy mode)
setFetchStrategy in interface NSessionpublic NSession addListener(NListener listener)
addListener in interface NSessionpublic NSession removeListener(NListener listener)
removeListener in interface NSessionpublic <T extends NListener> List<T> getListeners(Class<T> type)
getListeners in interface NSessionpublic List<NListener> getListeners()
getListeners in interface NSessionpublic NPropertiesHolder getPropertiesHolder()
public NOptional<NConfirmationMode> getConfirm()
getConfirm in interface NSessionpublic NSession setConfirm(NConfirmationMode confirm)
setConfirm in interface NSessionpublic NSession addOutputFormatOptions(String... options)
addOutputFormatOptions in interface NSessionpublic List<String> getOutputFormatOptions()
getOutputFormatOptions in interface NSessionpublic NSession setOutputFormatOptions(String... options)
setOutputFormatOptions in interface NSessionpublic NSession setOutputFormatOptions(List<String> options)
setOutputFormatOptions in interface NSessionpublic NPrintStream out()
public InputStream in()
public NPrintStream err()
public NIterableFormat getIterableOutput()
getIterableOutput in interface NSessionpublic NTerminal getTerminal()
getTerminal in interface NSessionpublic NSession setTerminal(NTerminal terminal)
setTerminal in interface NSessionpublic NWorkspace getWorkspace()
getWorkspace in interface NSessionpublic NOptional<Boolean> getTransitive()
getTransitive in interface NSessionpublic boolean isTransitive()
isTransitive in interface NSessionpublic NSession setTransitive(Boolean value)
setTransitive in interface NSessionpublic NOptional<Boolean> getIndexed()
getIndexed in interface NSessionpublic NSession setIndexed(Boolean value)
setIndexed in interface NSessionpublic NOptional<Instant> getExpireTime()
getExpireTime in interface NSessionpublic NSession setExpireTime(Instant expireTime)
setExpireTime in interface NSessionpublic String getProgressOptions()
getProgressOptions in interface NSessionpublic boolean isProgress()
isProgress in interface NSessionpublic NSession setProgressOptions(String progressOptions)
setProgressOptions in interface NSessionpublic String getErrLinePrefix()
getErrLinePrefix in interface NSessionpublic NSession setErrLinePrefix(String errLinePrefix)
setErrLinePrefix in interface NSessionpublic String getOutLinePrefix()
getOutLinePrefix in interface NSessionpublic NSession setOutLinePrefix(String outLinePrefix)
setOutLinePrefix in interface NSessionpublic NOptional<Boolean> getShowStacktrace()
getShowStacktrace in interface NSessionpublic NSession setShowStacktrace(Boolean showStacktrace)
setShowStacktrace in interface NSessionpublic Level getLogTermLevel()
getLogTermLevel in interface NSessionpublic NSession setLogTermLevel(Level level)
setLogTermLevel in interface NSessionpublic Filter getLogTermFilter()
getLogTermFilter in interface NSessionpublic NSession setLogFilter(Filter filter)
setLogFilter in interface NSessionpublic NSession configure(NWorkspaceOptions options)
public Level getLogFileLevel()
getLogFileLevel in interface NSessionpublic NSession setLogFileLevel(Level logFileLevel)
setLogFileLevel in interface NSessionpublic Filter getLogFileFilter()
getLogFileFilter in interface NSessionpublic NSession setLogFileFilter(Filter logFileFilter)
setLogFileFilter in interface NSessionpublic NArrayElementBuilder eout()
public NOptional<NExecutionType> getExecutionType()
getExecutionType in interface NSessionpublic NSession setExecutionType(NExecutionType executionType)
setExecutionType in interface NSessionpublic NSession currentUser()
currentUser in interface NSessionpublic String getDependencySolver()
getDependencySolver in interface NSessionpublic NSession setDependencySolver(String dependencySolver)
setDependencySolver in interface NSessionCopyright © 2025 vpc open source initiative. All rights reserved.