Codota Logo
openllet.core.datatypes
Code IndexAdd Codota to your IDE (free)

How to use openllet.core.datatypes

Best Java code snippets using openllet.core.datatypes (Showing top 20 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
LocalDateTime l =
  • Codota Iconnew LocalDateTime()
  • Codota IconLocalDateTime.now()
  • Codota IconDateTimeFormatter formatter;String text;formatter.parseLocalDateTime(text)
  • Smart code suggestions by Codota
}
origin: Galigator/openllet

private static int compareUpperLower(final OWLRealInterval a, final OWLRealInterval b)
{
  int ul;
  if (!a.boundUpper())
    ul = 1;
  else
    if (!b.boundLower())
      ul = 1;
    else
      ul = OWLRealUtils.compare(a.getUpper(), b.getLower());
  return ul;
}
origin: Galigator/openllet

@Override
public ATermAppl getCanonicalRepresentation(final ATermAppl input) throws InvalidLiteralException
{
  return _range.getDatatype().getCanonicalRepresentation(input);
}
origin: Galigator/openllet

@Override
public Datatype<?> getPrimitiveDatatype()
{
  return _range.getDatatype().getPrimitiveDatatype();
}
origin: Galigator/openllet

/**
 * Get the subinterval greater than n
 *
 * @param n
 * @return a new interval, formed by intersecting this interval with (n,+inf) or <code>null</code> if that intersection is empty
 */
public OWLRealInterval greater(final Number n)
{
  if (boundLower() && OWLRealUtils.compare(n, getLower()) < 0)
    return this;
  else
    if (boundUpper() && OWLRealUtils.compare(n, getUpper()) >= 0)
      return null;
  return new OWLRealInterval(n, getUpper(), false, inclusiveUpper(), getType());
}
origin: Galigator/openllet

@Override
public String toString()
{
  return format("%s%s,%s%s%s", inclusiveLower() ? "[" : "(", boundLower() ? getLower() : "-Inf", boundUpper() ? getUpper() : "+Inf", inclusiveUpper() ? "]" : ")", _type.equals(LineType.CONTINUOUS) ? "" : _type.equals(LineType.INTEGER_ONLY) ? "{int}" : "{noint}");
}
origin: Galigator/openllet

public RestrictedRealDatatype(final Datatype<? extends Number> datatype, final OWLRealInterval interval)
{
  _datatype = datatype;
  _empty = new EmptyRestrictedDatatype<>(datatype);
  _intervals = Collections.singletonList(interval);
  _finite = interval.isFinite();
  _enumerable = interval.isPoint() || interval.getType().equals(OWLRealInterval.LineType.INTEGER_ONLY);
}
origin: Galigator/openllet

@Override
public boolean containsAtLeast(final int n)
{
  if (n <= 0)
    return true;
  Number sum = _containsNaN ? 1 : 0;
  for (final FloatingPointInterval<T> i : _intervals)
  {
    sum = OWLRealUtils.integerSum(sum, i.size());
    if (OWLRealUtils.compare(sum, n) >= 0)
      return true;
  }
  return false;
}
origin: Galigator/openllet

@Override
public boolean containsAtLeast(final int n)
{
  if (!_finite || n <= 0)
    return true;
  Number sum = 0;
  for (final OWLRealInterval i : _intervals)
  {
    sum = OWLRealUtils.integerSum(sum, i.size());
    if (OWLRealUtils.compare(n, sum) <= 0)
      return true;
  }
  return false;
}
origin: Galigator/openllet

public static <U extends Number & Comparable<U>> FloatingPointInterval<U> unconstrained(final FloatingPointType<U> type)
{
  return new FloatingPointInterval<>(type, type.getNegativeInfinity(), type.getPositiveInfinity());
}
origin: Galigator/openllet

public RestrictedFloatingPointDatatype(final Datatype<? extends T> datatype, final FloatingPointType<T> type)
{
  this._datatype = datatype;
  this._type = type;
  this._empty = new EmptyRestrictedDatatype<>(datatype);
  this._intervals = Collections.singletonList(FloatingPointInterval.unconstrained(type));
  this._containsNaN = true;
}
origin: Galigator/openllet

@Override
public Datatype<?> getPrimitiveDatatype()
{
  return XSDDecimal.getInstance();
}
origin: Galigator/openllet

@Override
public Double increment(final Double n)
{
  return FloatingPointUtils.increment(n);
}
origin: Galigator/openllet

@Override
public Number intervalSize(final Float lower, final Float upper)
{
  return FloatingPointUtils.intervalSize(lower, upper);
}
origin: Galigator/openllet

private static int compareUpperLower(final OWLRealInterval a, final OWLRealInterval b)
{
  int ul;
  if (!a.boundUpper())
    ul = 1;
  else
    if (!b.boundLower())
      ul = 1;
    else
      ul = OWLRealUtils.compare(a.getUpper(), b.getLower());
  return ul;
}
origin: Galigator/openllet

public RestrictedRealDatatype(final Datatype<? extends Number> datatype, final OWLRealInterval interval)
{
  _datatype = datatype;
  _empty = new EmptyRestrictedDatatype<>(datatype);
  _intervals = Collections.singletonList(interval);
  _finite = interval.isFinite();
  _enumerable = interval.isPoint() || interval.getType().equals(OWLRealInterval.LineType.INTEGER_ONLY);
}
origin: Galigator/openllet

@Override
public boolean containsAtLeast(final int n)
{
  if (n <= 0)
    return true;
  Number sum = _containsNaN ? 1 : 0;
  for (final FloatingPointInterval<T> i : _intervals)
  {
    sum = OWLRealUtils.integerSum(sum, i.size());
    if (OWLRealUtils.compare(sum, n) >= 0)
      return true;
  }
  return false;
}
origin: Galigator/openllet

@Override
public boolean containsAtLeast(final int n)
{
  if (!_finite || n <= 0)
    return true;
  Number sum = 0;
  for (final OWLRealInterval i : _intervals)
  {
    sum = OWLRealUtils.integerSum(sum, i.size());
    if (OWLRealUtils.compare(n, sum) <= 0)
      return true;
  }
  return false;
}
origin: Galigator/openllet

public static <U extends Number & Comparable<U>> FloatingPointInterval<U> unconstrained(final FloatingPointType<U> type)
{
  return new FloatingPointInterval<>(type, type.getNegativeInfinity(), type.getPositiveInfinity());
}
origin: Galigator/openllet

@Override
public ATermAppl getCanonicalRepresentation(final ATermAppl input) throws InvalidLiteralException
{
  return _range.getDatatype().getCanonicalRepresentation(input);
}
origin: Galigator/openllet

@Override
public Datatype<?> getPrimitiveDatatype()
{
  return _range.getDatatype().getPrimitiveDatatype();
}
openllet.core.datatypes

Most used classes

  • DatatypeReasoner
  • DatatypeReasonerImpl
    Title: Datatype Reasoner Implementation Description: Default implementation of interface Datatype
  • DNF
  • Facet$Registry
  • Facet$XSD
    Facets in the XSD name space (and documented in the XML Schema specifications)
  • OWLRealInterval$LineType,
  • OWLRealInterval,
  • OWLRealUtils,
  • RestrictedDatatype,
  • DatatypeReasonerException,
  • RestrictedTimelineDatatype,
  • FloatingPointUtils,
  • ContinuousRealInterval,
  • IntegerInterval,
  • Rational,
  • RestrictedRealDatatype,
  • XSDByte,
  • XSDDecimal,
  • XSDInteger
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