// // ogis-queryable.idl // // Queryable collection definitions from the OpenGIS Simple Features // Specification for CORBA. // // // Taken from the PDF document _OpenGIS(R) Simple Features // Specification For CORBA_, Revision 1.1, dated June 2, 1999. // // Separated major sections into separate files in order to support // greater flexibility in the use of the module. // // Minor modifications made to restore readability after extraction // from the PDF document and to satisfy the TAO 1.4.6 IDL compiler. // // The aforementioned specification contains the following copyright // claims: // // Copyright 1997, 1998, 1999 Bentley Systems, Inc. // Copyright 1997, 1998, 1999 Environmental Systems Research Institute // Copyright 1997, 1998, 1999 Genasys II, Inc. // Copyright 1997, 1998, 1999 Oracle Corporation // Copyright 1997, 1998, 1999 University of California, Los Angeles. // Copyright 1997, 1998, 1999 Sun Microsystems, Inc. // // See the aforementioned specification for disclaimers and more // information. // // // Chuck Taylor, September 20, 2005. // // #ifndef _OGIS_QUERYABLE_IDL_ #define _OGIS_QUERYABLE_IDL_ #include "ogis-feature.idl" module OGIS { //---------------------------------------------------------------------- // Queryable Collection Interfaces //---------------------------------------------------------------------- //---------------------------------------------------------------------- // QueryEvaluator Interface //---------------------------------------------------------------------- interface QueryableFeatureCollection; // forward declaration interface QueryEvaluator { exception QueryLanguageTypeNotSupported {}; exception InvalidQuery {string why;}; exception QueryProcessingError {string why;}; exception InvalidGeometry {string why;}; exception InvalidSpatialOperator {}; enum QLType { SQLQuery, SQL_92Query, OQL, OQLBasic, OQL_93, OQL_93Basic }; typedef sequence QLTypeSeq; enum SpatialOperatorType { TouchOp, ContainsOp, WithinOp, DisjointOp, CrossesOp, OverlapsOp, IntersectsOp }; readonly attribute QLTypeSeq ql_types; readonly attribute QLType default_ql_type; enum GeomSwitch { GeomType, WKSGeomType }; union QueryGeom switch ( GeomSwitch ) { case GeomType: Geometry geom; case WKSGeomType: WKSGeometry wks_geom; }; struct GeomConstraint { Istring geom_name; SpatialOperatorType spatial_op; QueryGeom geo; }; typedef sequence GeomConstraintSeq; QueryableFeatureCollection query( in string where_clause, in QLType ql_type, in GeomConstraintSeq geom_constraints ) raises(QueryLanguageTypeNotSupported, InvalidQuery, InvalidGeometry, QueryProcessingError, InvalidSpatialOperator); }; //---------------------------------------------------------------------- // QueryableFeatureCollection Interface //---------------------------------------------------------------------- interface QueryableFeatureCollection : FeatureCollection, QueryEvaluator { }; //---------------------------------------------------------------------- // QueryableFeatureCollectionFactory Interface //---------------------------------------------------------------------- interface QueryableFeatureCollectionFactory { exception FeatureTypeInvalid {string why;}; exception PropertyInvalid {string why;}; exception FeatureInvalid {string why;}; QueryableFeatureCollection create(in FeatureType collection_type, in NVPairSeq collection_properties) raises (FeatureTypeInvalid, PropertyInvalid); QueryableFeatureCollection createFromCollection( in FeatureType collection_type, in NVPairSeq collection_properties, in FeatureCollection collection) raises (FeatureTypeInvalid,PropertyInvalid,FeatureInvalid); QueryableFeatureCollection createFromSequence( in FeatureType collection_type, in NVPairSeq collection_properties, in FeatureSeq list) raises (FeatureTypeInvalid,PropertyInvalid,FeatureInvalid); QueryableFeatureCollection createFromFeatureData( in FeatureType collection_type, in NVPairSeq collection_properties, in FeatureDataSeq list) raises (FeatureTypeInvalid,PropertyInvalid,FeatureInvalid); }; //---------------------------------------------------------------------- // QueryableContainerFeatureCollection Interface //---------------------------------------------------------------------- interface QueryableContainerFeatureCollection: ContainerFeatureCollection, QueryEvaluator { }; //---------------------------------------------------------------------- // QueryableContainerFeatureCollectionFactory Interface //---------------------------------------------------------------------- interface QueryableContainerFeatureCollectionFactory { exception FeatureTypeInvalid {string why;}; exception PropertyInvalid {string why;}; exception FeatureInvalid {string why;}; QueryableContainerFeatureCollection create( in FeatureType collection_type, in NVPairSeq collection_properties) raises (FeatureTypeInvalid, PropertyInvalid); QueryableContainerFeatureCollection createFromCollection( in FeatureType collection_type, in NVPairSeq collection_properties, in FeatureCollection collection) raises (FeatureTypeInvalid,PropertyInvalid,FeatureInvalid); QueryableContainerFeatureCollection createFromSequence( in FeatureType collection_type, in NVPairSeq collection_properties, in FeatureSeq list) raises (FeatureTypeInvalid,PropertyInvalid,FeatureInvalid); QueryableContainerFeatureCollection createFromFeatureData( in FeatureType collection_type, in NVPairSeq collection_properties, in FeatureDataSeq list) raises (FeatureTypeInvalid,PropertyInvalid,FeatureInvalid); }; }; // End OGIS Module #endif // _OGIS_QUERYABLE_IDL_