Codota Logo
SystemInfoFactory.createSystemInfo
Code IndexAdd Codota to your IDE (free)

How to use
createSystemInfo
method
in
org.rhq.core.system.SystemInfoFactory

Best Java code snippets using org.rhq.core.system.SystemInfoFactory.createSystemInfo (Showing top 13 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
OutputStreamWriter o =
  • Codota IconOutputStream out;new OutputStreamWriter(out)
  • Codota IconOutputStream out;String charsetName;new OutputStreamWriter(out, charsetName)
  • Codota IconHttpURLConnection connection;new OutputStreamWriter(connection.getOutputStream())
  • Smart code suggestions by Codota
}
origin: org.rhq/rhq-core-plugin-container

private List<ProcessInfo> getProcessInfos() {
  SystemInfo systemInfo = SystemInfoFactory.createSystemInfo();
  log.debug("Retrieving process table...");
  long startTime = System.currentTimeMillis();
  List<ProcessInfo> processInfos = null;
  try {
    processInfos = systemInfo.getAllProcesses();
  } catch (UnsupportedOperationException uoe) {
    log.debug("Cannot perform process scan - not supported on this platform. (" + systemInfo.getClass() + ")");
  }
  long elapsedTime = System.currentTimeMillis() - startTime;
  if (log.isDebugEnabled()) {
    log.debug("Retrieval of process table took " + elapsedTime + " ms.");
  }
  return processInfos;
}
origin: org.rhq/rhq-core-plugin-container

private PluginContext createPluginContext(String pluginName) {
  SystemInfo sysInfo = SystemInfoFactory.createSystemInfo();
  File dataDir = new File(pluginContainerConfiguration.getDataDirectory(), pluginName);
  File tmpDir = pluginContainerConfiguration.getTemporaryDirectory();
  String pcName = pluginContainerConfiguration.getContainerName();
  PluginContext context = new PluginContext(pluginName, sysInfo, tmpDir, dataDir, pcName);
  return context;
}
origin: org.rhq/rhq-cassandra-ccm-core

private ProcessExecutionResults startNode(File basedir) {
  if (log.isDebugEnabled()) {
    log.debug("Starting node at " + basedir);
  }
  File binDir = new File(basedir, "bin");
  File startScript;
  SystemInfo systemInfo = SystemInfoFactory.createSystemInfo();
  ProcessExecution startScriptExe;
  if (systemInfo.getOperatingSystemType() == OperatingSystemType.WINDOWS) {
    startScript = new File(binDir, "cassandra.bat");
    startScriptExe = createProcessExecution(null, startScript);
  } else {
    startScript = new File(binDir, "cassandra");
    startScriptExe = createProcessExecution(null, startScript);
    startScriptExe.addArguments(Arrays.asList("-p", "cassandra.pid"));
  }
  startScriptExe.setWaitForCompletion(0);
  ProcessExecutionResults results = systemInfo.executeProcess(startScriptExe);
  if (log.isDebugEnabled()) {
    log.debug(startScript + " returned with exit code [" + results.getExitCode() + "]");
  }
  return results;
}
origin: org.rhq/rhq-cassandra-ccm-core

SystemInfo systemInfo = SystemInfoFactory.createSystemInfo();
origin: org.rhq/rhq-core-native-system

public static TemplateEngine fetchTemplateEngine() {
    SystemInfo systemInfo = createSystemInfo();
origin: rhq-project/rhq

public static TemplateEngine fetchTemplateEngine() {
    SystemInfo systemInfo = createSystemInfo();
origin: org.rhq/rhq-core-plugin-api

SystemInfo systemInfo = SystemInfoFactory.createSystemInfo();
origin: org.rhq/rhq-core-plugin-container

SystemInfo systemInfo = SystemInfoFactory.createSystemInfo();
PluginMetadataManager metadataManager = pluginManager.getMetadataManager();
Set<ResourceType> platformTypes = metadataManager.getTypesForCategory(ResourceCategory.PLATFORM);
origin: org.rhq/rhq-core-plugin-container

try {
  ResourceDiscoveryContext context = new ResourceDiscoveryContext(resourceType, parentComponent,
    parentResourceContext, SystemInfoFactory.createSystemInfo(), processScanResults,
    Collections.EMPTY_LIST, this.configuration.getContainerName(),
    this.configuration.getPluginContainerDeployment());
origin: org.rhq/rhq-core-plugin-container

public <T extends ResourceComponent<?>> ResourceUpgradeContext<T> createResourceUpgradeContext(Resource resource,
  ResourceContext<?> parentResourceContext, T parentComponent, ResourceDiscoveryComponent<T> discoveryComponent) {
  return new ResourceUpgradeContext<T>(resource, // the resource itself
    parentResourceContext, //the context of its parent resource
    parentComponent, // its parent component
    discoveryComponent, // the discovery component (this is actually the proxy to it)
    SystemInfoFactory.createSystemInfo(), // for native access
    this.configuration.getTemporaryDirectory(), // location for plugin to write temp files
    this.configuration.getDataDirectory(), // base location for plugin to write data files
    this.configuration.getContainerName(), // the name of the agent/PC
    getEventContext(resource), // for event access
    getOperationContext(resource), // for operation manager access
    getContentContext(resource), // for content manager access
    getAvailabilityContext(resource), // for components that want avail manager access
    getInventoryContext(resource), this.configuration.getPluginContainerDeployment()); // helps components make determinations of what to do
}
origin: org.rhq/rhq-core-plugin-container

  SystemInfoFactory.createSystemInfo(), new ArrayList<ProcessScanResult>(0),
  new ArrayList<Configuration>(0), this.configuration.getContainerName(),
  this.configuration.getPluginContainerDeployment());
ResourceDiscoveryContext<ResourceComponent<?>> discoveryContext = new ResourceDiscoveryContext<ResourceComponent<?>>(
  resourceType, parentResourceComponent, parentResourceContainer.getResourceContext(),
  SystemInfoFactory.createSystemInfo(), new ArrayList<ProcessScanResult>(0), pluginConfigurations,
  this.configuration.getContainerName(), this.configuration.getPluginContainerDeployment());
origin: org.rhq/rhq-core-plugin-container

private <T extends ResourceComponent<?>> ResourceContext<T> createResourceContext(Resource resource,
  T parentComponent, ResourceContext<?> parentResourceContext, ResourceDiscoveryComponent<T> discoveryComponent) {
  return new ResourceContext<T>(resource, // the resource itself
    parentComponent, // its parent component
    parentResourceContext, //the resource context of the parent
    discoveryComponent, // the discovery component (this is actually the proxy to it)
    SystemInfoFactory.createSystemInfo(), // for native access
    this.configuration.getTemporaryDirectory(), // location for plugin to write temp files
    this.configuration.getDataDirectory(), // base location for plugin to write data files
    this.configuration.getContainerName(), // the name of the agent/PC
    getEventContext(resource), // for event access
    getOperationContext(resource), // for operation manager access
    getContentContext(resource), // for content manager access
    getAvailabilityContext(resource), getInventoryContext(resource),
    this.configuration.getPluginContainerDeployment(), // helps components make determinations of what to do
    new ComponentInvocationContextImpl());
}
origin: org.rhq/rhq-core-plugin-container

parentResourceContext, SystemInfoFactory.createSystemInfo(), null, null,
this.configuration.getContainerName(), this.configuration.getPluginContainerDeployment());
org.rhq.core.systemSystemInfoFactorycreateSystemInfo

Javadoc

Returns the appropriate SystemInfo implementation based on the platform/operating system the JVM is running on.

Popular methods of SystemInfoFactory

  • isNativeSystemInfoDisabled
    Returns true if this factory was told to #disableNativeSystemInfo() the native layer. This only indi
  • disableNativeSystemInfo
    This will tell the factory to not #createSystemInfo() any native objects and to not load the native
  • isNativeSystemInfoAvailable
    If there is a native library available for the JVM's platform/operating system, true is returned. I
  • isNativeSystemInfoInitialized
    This returns true iff the native libraries have actually been initialized. This will return false if
  • createJavaSystemInfo
    Under some circumstances, you may want to force this factory to provide a Java-only SystemInfoimplem
  • enableNativeSystemInfo
    This will allow the factory to load the native libraries and #createSystemInfo() native objects. Not
  • getNativeSystemInfoVersion
    If the native system is both #isNativeSystemInfoAvailable() and #isNativeSystemInfoDisabled(), this
  • initialize
    This will initialize the native layer, if applicable. If the native layer was already initialized, t
  • invokeApi
    In order for this class to not have any compile or load time dependencies on the SIGAR jar, use this

Popular in Java

  • Reading from database using SQL prepared statement
  • putExtra (Intent)
  • findViewById (Activity)
  • getSystemService (Context)
  • HttpServer (com.sun.net.httpserver)
    This class implements a simple HTTP server. A HttpServer is bound to an IP address and port number a
  • Font (java.awt)
    The Font class represents fonts, which are used to render text in a visible way. A font provides the
  • Graphics2D (java.awt)
    This Graphics2D class extends the Graphics class to provide more sophisticated control overgraphics
  • Path (java.nio.file)
  • TimerTask (java.util)
    A task that can be scheduled for one-time or repeated execution by a Timer.
  • Notification (javax.management)
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now