congrats Icon
New! Announcing our next generation AI code completions
Read here
Tabnine Logo
IConstant.getValue
Code IndexAdd Tabnine to your IDE (free)

How to use
getValue
method
in
jscl.math.function.IConstant

Best Java code snippets using jscl.math.function.IConstant.getValue (Showing top 6 results out of 315)

origin: org.solovyev/jscl

@Override
public void copy(@Nonnull MathEntity that) {
  this.constant.copy(that);
  if (that instanceof IConstant) {
    this.description = ((IConstant) that).getDescription();
    this.value = ((IConstant) that).getValue();
  }
  if (that instanceof ExtendedConstant) {
    this.javaString = ((ExtendedConstant) that).javaString;
  }
}
origin: org.solovyev.android/calculatorpp-core

public void copy(@Nonnull MathEntity o) {
  if (o instanceof IConstant) {
    final IConstant that = ((IConstant) o);
    this.name = that.getName();
    this.value = that.getValue();
    this.description = that.getDescription();
    this.system = that.isSystem();
    if (that.isIdDefined()) {
      this.id = that.getId();
    }
  } else {
    throw new IllegalArgumentException("Trying to make a copy of unsupported type: " + o.getClass());
  }
}
origin: org.solovyev/jscl

@Nonnull
public static String toString(@Nonnull IConstant constant) {
  final Double doubleValue = constant.getDoubleValue();
  if (doubleValue == null) {
    final String stringValue = constant.getValue();
    if (!Strings.isEmpty(stringValue)) {
      return constant.getName() + " = " + stringValue;
    } else {
      return constant.getName();
    }
  } else {
    return constant.getName() + " = " + doubleValue;
  }
}
origin: org.solovyev.android/calculatorpp-core

public Builder(@Nonnull IConstant iConstant) {
  this.name = iConstant.getName();
  this.value = iConstant.getValue();
  this.system = iConstant.isSystem();
  this.description = iConstant.getDescription();
  if (iConstant.isIdDefined()) {
    this.id = iConstant.getId();
  }
}
origin: org.solovyev/jscl

public NumericWrapper(@Nonnull Constant constant) {
  final IConstant constantFromRegistry = JsclMathEngine.getInstance().getConstantsRegistry().get(constant.getName());
  if (constantFromRegistry != null) {
    if (constantFromRegistry.getName().equals(Constants.I.getName())) {
      content = Complex.I;
    } else {
      if (constantFromRegistry.getValue() != null) {
        final Double value = constantFromRegistry.getDoubleValue();
        if (value == null) {
          throw new ArithmeticException("Constant " + constant.getName() + " has invalid definition: " + constantFromRegistry.getValue());
        } else {
          content = Real.valueOf(value);
        }
      } else {
        throw new ArithmeticException("Could not create numeric wrapper: constant in registry doesn't have specified value: " + constant.getName());
      }
    }
  } else {
    throw new ArithmeticException("Could not create numeric wrapper: constant is not registered in constants registry: " + constant.getName());
  }
}
origin: org.solovyev.android/calculatorpp-core

  offset = varName.length();
} else {
  final String value = var.getValue();
  assert value != null;
jscl.math.functionIConstantgetValue

Popular methods of IConstant

  • getDescription
  • getDoubleValue
  • getName
  • getId
  • isDefined
  • isIdDefined
  • isSystem
  • toJava

Popular in Java

  • Making http requests using okhttp
  • getContentResolver (Context)
  • findViewById (Activity)
  • getSharedPreferences (Context)
  • BufferedWriter (java.io)
    Wraps an existing Writer and buffers the output. Expensive interaction with the underlying reader is
  • StringTokenizer (java.util)
    Breaks a string into tokens; new code should probably use String#split.> // Legacy code: StringTo
  • ConcurrentHashMap (java.util.concurrent)
    A plug-in replacement for JDK1.5 java.util.concurrent.ConcurrentHashMap. This version is based on or
  • JComboBox (javax.swing)
  • Get (org.apache.hadoop.hbase.client)
    Used to perform Get operations on a single row. To get everything for a row, instantiate a Get objec
  • Join (org.hibernate.mapping)
  • 21 Best Atom Packages for 2021
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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