static public ATermList toSet(Collection<ATermAppl> terms) { int size = terms.size(); ATermAppl[] a = new ATermAppl[size]; terms.toArray( a ); return toSet( a, size ); }
static public ATermList toSet(Collection<ATermAppl> terms) { int size = terms.size(); ATermAppl[] a = new ATermAppl[size]; terms.toArray( a ); return toSet( a, size ); }
public void addDisjointProperties(List<ATermAppl> properties) { addDisjointProperties( ATermUtils.toSet( properties ) ); }
public void addDisjointClasses(List<ATermAppl> classes) { addDisjointClasses( ATermUtils.toSet( classes ) ); }
public void addDisjointClasses(List<ATermAppl> classes) { addDisjointClasses( ATermUtils.toSet( classes ) ); }
public void addDisjointProperties(List<ATermAppl> properties) { addDisjointProperties( ATermUtils.toSet( properties ) ); }
private static void addTo(Map<ATermAppl, ATermAppl> map, ATermAppl roleName, Set<ATermAppl> asserted) { if (asserted.isEmpty()) return; ATermAppl range = null; if (asserted.size() == 1) { range = asserted.iterator().next(); } else { range = ATermUtils.makeAnd(ATermUtils.toSet(asserted)); } range = ELSyntaxUtils.simplify( ATermUtils.nnf( range ) ); map.put(roleName, range); }
private static void addTo(Map<ATermAppl, ATermAppl> map, ATermAppl roleName, Set<ATermAppl> asserted) { if (asserted.isEmpty()) return; ATermAppl range = null; if (asserted.size() == 1) { range = asserted.iterator().next(); } else { range = ATermUtils.makeAnd(ATermUtils.toSet(asserted)); } range = ELSyntaxUtils.simplify( ATermUtils.nnf( range ) ); map.put(roleName, range); }
public void visit(OWLObjectUnionOf or) { Set<OWLClassExpression> operands = or.getOperands(); ATerm[] terms = new ATerm[operands.size()]; int size = 0; for( OWLClassExpression desc : operands ) { desc.accept( this ); terms[size++] = term; } // create a sorted set of terms so we will have a stable // concept creation and removal using this concept will work ATermList setOfTerms = size > 0 ? ATermUtils.toSet( terms, size ) : ATermUtils.EMPTY_LIST; term = ATermUtils.makeOr( setOfTerms ); }
public void visit(OWLDataUnionOf or) { Set<OWLDataRange> operands = or.getOperands(); ATerm[] terms = new ATerm[operands.size()]; int size = 0; for( OWLDataRange desc : operands ) { desc.accept( this ); terms[size++] = term; } // create a sorted set of terms so we will have a stable // concept creation and removal using this concept will work ATermList setOfTerms = size > 0 ? ATermUtils.toSet( terms, size ) : ATermUtils.EMPTY_LIST; term = ATermUtils.makeOr( setOfTerms ); }
public void visit(OWLObjectIntersectionOf and) { Set<OWLClassExpression> operands = and.getOperands(); ATerm[] terms = new ATerm[operands.size()]; int size = 0; for( OWLClassExpression desc : operands ) { desc.accept( this ); terms[size++] = term; } // create a sorted set of terms so we will have a stable // concept creation and removal using this concept will work ATermList setOfTerms = size > 0 ? ATermUtils.toSet( terms, size ) : ATermUtils.EMPTY_LIST; term = ATermUtils.makeAnd( setOfTerms ); }
public void visit(OWLDataIntersectionOf and) { Set<OWLDataRange> operands = and.getOperands(); ATerm[] terms = new ATerm[operands.size()]; int size = 0; for( OWLDataRange desc : operands ) { desc.accept( this ); terms[size++] = term; } // create a sorted set of terms so we will have a stable // concept creation and removal using this concept will work ATermList setOfTerms = size > 0 ? ATermUtils.toSet( terms, size ) : ATermUtils.EMPTY_LIST; term = ATermUtils.makeAnd( setOfTerms ); }
@Override public void visit(OWLDataUnionOf or) { Set<OWLDataRange> operands = or.getOperands(); ATerm[] terms = new ATerm[operands.size()]; int size = 0; for( OWLDataRange desc : operands ) { desc.accept( this ); terms[size++] = term; } // create a sorted set of terms so we will have a stable // concept creation and removal using this concept will work ATermList setOfTerms = size > 0 ? ATermUtils.toSet( terms, size ) : ATermUtils.EMPTY_LIST; term = ATermUtils.makeOr( setOfTerms ); }
@Override public void visit(OWLObjectIntersectionOf and) { Set<OWLClassExpression> operands = and.getOperands(); ATerm[] terms = new ATerm[operands.size()]; int size = 0; for( OWLClassExpression desc : operands ) { desc.accept( this ); terms[size++] = term; } // create a sorted set of terms so we will have a stable // concept creation and removal using this concept will work ATermList setOfTerms = size > 0 ? ATermUtils.toSet( terms, size ) : ATermUtils.EMPTY_LIST; term = ATermUtils.makeAnd( setOfTerms ); }
@Override public void visit(OWLDataIntersectionOf and) { Set<OWLDataRange> operands = and.getOperands(); ATerm[] terms = new ATerm[operands.size()]; int size = 0; for( OWLDataRange desc : operands ) { desc.accept( this ); terms[size++] = term; } // create a sorted set of terms so we will have a stable // concept creation and removal using this concept will work ATermList setOfTerms = size > 0 ? ATermUtils.toSet( terms, size ) : ATermUtils.EMPTY_LIST; term = ATermUtils.makeAnd( setOfTerms ); }
@Override public void visit(OWLObjectUnionOf or) { Set<OWLClassExpression> operands = or.getOperands(); ATerm[] terms = new ATerm[operands.size()]; int size = 0; for( OWLClassExpression desc : operands ) { desc.accept( this ); terms[size++] = term; } // create a sorted set of terms so we will have a stable // concept creation and removal using this concept will work ATermList setOfTerms = size > 0 ? ATermUtils.toSet( terms, size ) : ATermUtils.EMPTY_LIST; term = ATermUtils.makeOr( setOfTerms ); }
public void visit(OWLObjectOneOf enumeration) { Set<OWLIndividual> operands = enumeration.getIndividuals(); ATerm[] terms = new ATerm[operands.size()]; int size = 0; for( OWLIndividual ind : operands ) { ind.accept( this ); terms[size++] = ATermUtils.makeValue( term ); } // create a sorted set of terms so we will have a stable // concept creation and removal using this concept will work ATermList setOfTerms = size > 0 ? ATermUtils.toSet( terms, size ) : ATermUtils.EMPTY_LIST; term = ATermUtils.makeOr( setOfTerms ); }
@Override public void visit(OWLObjectOneOf enumeration) { Set<OWLIndividual> operands = enumeration.getIndividuals(); ATerm[] terms = new ATerm[operands.size()]; int size = 0; for( OWLIndividual ind : operands ) { ind.accept( this ); terms[size++] = ATermUtils.makeValue( term ); } // create a sorted set of terms so we will have a stable // concept creation and removal using this concept will work ATermList setOfTerms = size > 0 ? ATermUtils.toSet( terms, size ) : ATermUtils.EMPTY_LIST; term = ATermUtils.makeOr( setOfTerms ); }
public static ATermList normalize(ATermList list) { int size = list.getLength(); ATerm[] terms = new ATerm[size]; for( int i = 0; i < size; i++ ) { terms[i] = normalize( (ATermAppl) list.getFirst() ); list = list.getNext(); } ATermList set = toSet( terms, size ); return set; }
public static ATermList normalize(ATermList list) { int size = list.getLength(); ATerm[] terms = new ATerm[size]; for( int i = 0; i < size; i++ ) { terms[i] = normalize( (ATermAppl) list.getFirst() ); list = list.getNext(); } ATermList set = toSet( terms, size ); return set; }