001: /*****************************************************************************
002: * Source code information
003: * -----------------------
004: * Original author Ian Dickinson, HP Labs Bristol
005: * Author email ian.dickinson@hp.com
006: * Package Jena 2
007: * Web http://sourceforge.net/projects/jena/
008: * Created 08-Sep-2003
009: * Filename $RCSfile: MinCardinalityQRestriction.java,v $
010: * Revision $Revision: 1.7 $
011: * Release status $State: Exp $
012: *
013: * Last modified on $Date: 2008/01/02 12:06:41 $
014: * by $Author: andy_seaborne $
015: *
016: * (c) Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Hewlett-Packard Development Company, LP
017: * [See end of file]
018: *****************************************************************************/package com.hp.hpl.jena.ontology;
019:
020: // Imports
021: ///////////////
022:
023: /**
024: * <p>
025: * Interface representing the ontology abstraction for a qualified minimum cardinality
026: * restriction. A qualified restriction is a DAML+OIL term for a restriction
027: * with a cardinality constraint <em>and</em> a constraint that the values of
028: * the restricted property must all belong to the given class. At the current
029: * time, qualified restrictions are part of DAML+OIL, but not part of OWL.
030: * </p>
031: *
032: * @author Ian Dickinson, HP Labs
033: * (<a href="mailto:Ian.Dickinson@hp.com" >email</a>)
034: * @version CVS $Id: MinCardinalityQRestriction.java,v 1.7 2008/01/02 12:06:41 andy_seaborne Exp $
035: */
036: public interface MinCardinalityQRestriction extends
037: QualifiedRestriction {
038: // Constants
039: //////////////////////////////////
040:
041: // External signature methods
042: //////////////////////////////////
043:
044: /**
045: * <p>Assert that this restriction restricts the property to have the given
046: * minimum cardinality. Any existing statements for <code>minCardinalityQ</code>
047: * will be removed.</p>
048: * @param minCardinality The minimum cardinality of the restricted property
049: * @exception OntProfileException If the {@link Profile#MIN_CARDINALITY_Q()} property is not supported in the current language profile.
050: */
051: public void setMinCardinalityQ(int minCardinality);
052:
053: /**
054: * <p>Answer the min qualified cardinality of the restricted property.</p>
055: * @return The cardinality of the restricted property
056: * @exception OntProfileException If the {@link Profile#MIN_CARDINALITY_Q()} property is not supported in the current language profile.
057: */
058: public int getMinCardinalityQ();
059:
060: /**
061: * <p>Answer true if this property restriction has the given minimum qualifed cardinality.</p>
062: * @param minCardinality The cardinality to test against
063: * @return True if the given cardinality is the minimum qualified cardinality of the restricted property in this restriction
064: * @exception OntProfileException If the {@link Profile#MIN_CARDINALITY_Q()} property is not supported in the current language profile.
065: */
066: public boolean hasMinCardinalityQ(int minCardinality);
067:
068: /**
069: * <p>Remove the statement that this restriction has the given minimum qualified cardinality
070: * for the restricted property. If this statement
071: * is not true of the current model, nothing happens.</p>
072: * @param minCardinality A cardinality value to be removed from this restriction
073: * @exception OntProfileException If the {@link Profile#MIN_CARDINALITY_Q()} property is not supported in the current language profile.
074: */
075: public void removeMinCardinalityQ(int minCardinality);
076:
077: }
078:
079: /*
080: * (c) Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Hewlett-Packard Development Company, LP
081: * All rights reserved.
082: *
083: * Redistribution and use in source and binary forms, with or without
084: * modification, are permitted provided that the following conditions
085: * are met:
086: * 1. Redistributions of source code must retain the above copyright
087: * notice, this list of conditions and the following disclaimer.
088: * 2. Redistributions in binary form must reproduce the above copyright
089: * notice, this list of conditions and the following disclaimer in the
090: * documentation and/or other materials provided with the distribution.
091: * 3. The name of the author may not be used to endorse or promote products
092: * derived from this software without specific prior written permission.
093: *
094: * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
095: * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
096: * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
097: * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
098: * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
099: * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
100: * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
101: * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
102: * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
103: * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
104: */
|