Tabnine Logo
FloatResource.getHistoricalData
Code IndexAdd Tabnine to your IDE (free)

How to use
getHistoricalData
method
in
org.ogema.core.model.simple.FloatResource

Best Java code snippets using org.ogema.core.model.simple.FloatResource.getHistoricalData (Showing top 5 results out of 315)

origin: org.ogema.tools/resource-manipulators

private static RecordedData getHistoricalData(SingleValueResource resource) {
  RecordedData rd = null;
  if (resource instanceof FloatResource)
    rd = ((FloatResource) resource).getHistoricalData();
  else if (resource instanceof IntegerResource)
    rd = ((IntegerResource) resource).getHistoricalData();
  else if (resource instanceof TimeResource)
    rd = ((TimeResource) resource).getHistoricalData();
  else if (resource instanceof BooleanResource)
    rd = ((BooleanResource) resource).getHistoricalData();
  else 
    throw new IllegalArgumentException("Logging not possible for resource of type " + resource.getResourceType().getName());
  return rd;
}
 
origin: org.ogema.tools/resource-utils

/**
 * See also {@link #getHistoricalDataSchedule(SingleValueResource)}, which provides an alternative
 * access to log data, via a {@link Schedule}.
 * @param resource
 * @return
 * @throws IllegalArgumentException
 *         if <code>resource</code> is a {@link StringResource}. Logging StringResources is not possible.
 */
public static RecordedData getHistoricalData(SingleValueResource resource) throws IllegalArgumentException {
  RecordedData rd = null;
  if (resource instanceof FloatResource)
    rd = ((FloatResource) resource).getHistoricalData();
  else if (resource instanceof IntegerResource)
    rd = ((IntegerResource) resource).getHistoricalData();
  else if (resource instanceof TimeResource)
    rd = ((TimeResource) resource).getHistoricalData();
  else if (resource instanceof BooleanResource)
    rd = ((BooleanResource) resource).getHistoricalData();
  else if (resource instanceof StringResource)
    throw new IllegalArgumentException("Logging for StringResources not possible");
  return rd;
}
origin: org.smartrplace.apps/smartrplace-util-proposed

  /** Get Recorded data from SingleValueResource
   * 
   * @param valueResource
   * @return null if type of resource does not support getHistoricalData
   */
  public static RecordedData getRecordedData(SingleValueResource valueResource) {
    if(valueResource instanceof FloatResource)
      return ((FloatResource)valueResource).getHistoricalData();
    if(valueResource instanceof IntegerResource)
      return ((IntegerResource)valueResource).getHistoricalData();
    if(valueResource instanceof TimeResource)
      return ((TimeResource)valueResource).getHistoricalData();
    if(valueResource instanceof BooleanResource)
      return ((BooleanResource)valueResource).getHistoricalData();
    return null;
  }
}
origin: org.ogema.ref-impl/resource-manager

private RecordedData getHistoricalData() {
  if (parentResource instanceof FloatResource) {
    return ((FloatResource) parentResource).getHistoricalData();
  }
  else if (parentResource instanceof BooleanResource) {
    return ((BooleanResource) parentResource).getHistoricalData();
  }
  else if (parentResource instanceof IntegerResource) {
    return ((IntegerResource) parentResource).getHistoricalData();
  }
  else if (parentResource instanceof TimeResource) {
    return ((TimeResource) parentResource).getHistoricalData();
  }
  else
    return null;
}
 
origin: org.ogema.tools/grafana-base

switch (dataType.getDataType()) {
case 0:
  ts = fl.getHistoricalData();
  break;
case 1:
org.ogema.core.model.simpleFloatResourcegetHistoricalData

Popular methods of FloatResource

  • getValue
  • setValue
  • create
  • isActive
  • exists
  • activate
  • addDecorator
  • addValueListener
  • historicalData
  • program
  • addStructureListener
  • forecast
  • addStructureListener,
  • forecast,
  • getParent,
  • getPath,
  • getSubResource,
  • removeStructureListener,
  • removeValueListener,
  • requestAccessMode,
  • setAsReference

Popular in Java

  • Reading from database using SQL prepared statement
  • setContentView (Activity)
  • onRequestPermissionsResult (Fragment)
  • addToBackStack (FragmentTransaction)
  • Rectangle (java.awt)
    A Rectangle specifies an area in a coordinate space that is enclosed by the Rectangle object's top-
  • BufferedReader (java.io)
    Wraps an existing Reader and buffers the input. Expensive interaction with the underlying reader is
  • AtomicInteger (java.util.concurrent.atomic)
    An int value that may be updated atomically. See the java.util.concurrent.atomic package specificati
  • Collectors (java.util.stream)
  • Response (javax.ws.rs.core)
    Defines the contract between a returned instance and the runtime when an application needs to provid
  • StringUtils (org.apache.commons.lang)
    Operations on java.lang.String that arenull safe. * IsEmpty/IsBlank - checks if a String contains
  • Top Vim plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now