2ronwalfeverything in a ControlConstructBag/ControlConstructList should be of type ControlConstruct
2ronwalf public OWLSValidatorReport validate(OWLOntology theOntology) throws OWLSValidationException
2ronwalf throw OWLSValidationException.createParseException("Invalid URI ("+theURI+") specified for description");
2ronwalf throw OWLSValidationException.createFileNotFoundException("File at URI ("+theURI+") not found, cannot validate");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_INVALID_VALUE,"Cannot specify more than one describedBy for a service");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"No process specified for service: "+theService.getLocalName());
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"No profile specified for process: "+theProcess.getLocalName());
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"Process '"+theProcess.getLocalName()+"' can specify at most one name");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"A paramType must be specified for Parameter: "+theParam.getLocalName());
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_INVALID_VALUE,"The paramType for parameter: '"+theParam.getLocalName()+"' is not specified properly. It is supposed to be a datatype property, but it is specifed as an Object property. Please change the declaration.");
7daenzerorama // Process aProcess = aProcessList.processAt(i);
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"No grounding specified for service: "+theService.getLocalName());
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_INVALID_VALUE,"The grounding '"+aGrounding.getLocalName()+"' cannot have more than one supportedBy property");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"The grounding '"+aGrounding.getLocalName()+"' does not specify a service.");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"The atomic grounding '"+aAtomicGrounding.getLocalName()+"' does not specify its process.");
2ronwalf validateWSDLAtomicGrounding(theService,(WSDLAtomicGrounding)aAtomicGrounding.castTo(WSDLAtomicGrounding.class));
2ronwalf private void validateWSDLAtomicGrounding(Service theService, WSDLAtomicGrounding theWSDLAtomicGrounding)
2ronwalf // todo: are the wsdlInputMessage/wsdlOutputMessage required? what about getWSDL()?
2ronwalf addMessage(theService,CODE_INVALID_VALUE,"The grounding '"+theWSDLAtomicGrounding.getLocalName()+"' has a missing, or invalid operationRef.");
2ronwalf addMessage(theService, CODE_MISSING_VALUE,"The grounding '"+theWSDLAtomicGrounding.getLocalName()+"' must specify a portType for its operationRef.");
2ronwalf addMessage(theService, CODE_MISSING_VALUE,"The grounding '"+theWSDLAtomicGrounding.getLocalName()+"' must specify an operation for its operationRef");
2ronwalf addMessage(theService,CODE_MISSING_VALUE,"The input map for grounding '"+theWSDLAtomicGrounding.getLocalName()+"' requires a grounding parameter (wsdlMessagePart).");
2ronwalf addMessage(theService,CODE_MISSING_VALUE,"The input map for grounding '"+theWSDLAtomicGrounding.getLocalName()+"' must specify either an owlsParameter or an xlstTransformation.");
2ronwalf addMessage(theService,CODE_MISSING_VALUE,"The output map for grounding '"+theWSDLAtomicGrounding.getLocalName()+"' requires an owlsParameter.");
2ronwalf addMessage(theService,CODE_MISSING_VALUE,"The output map for grounding '"+theWSDLAtomicGrounding.getLocalName()+"' must specify either an grounding parameter (wsdlMessagePart) or an xlstTransformation.");
2ronwalf private void validateControlConstruct(Service theService, ControlConstruct theControlConstruct)
7daenzerorama// OWLIndividual aInd = aList.individualAt(i);
2ronwalf addMessage(theService,CODE_MISSING_VALUE,"Result '"+theResult.getLocalName()+"' must specify an Output for its toParam property.");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"Perform '"+thePerform.getLocalName()+"' must specify a process");
2ronwalf addMessage(theService,CODE_MISSING_VALUE,"Perform '"+thePerform.getLocalName()+"' must specify an Input for the toParam property.");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"No profile specified for service: "+theService.getLocalName());
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"No service specified for profile: "+aProfile.getLocalName()+"; double check the presentedBy property on the profile to make sure its correctly specified");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"The profile '"+aProfile.getLocalName()+"' must specify only one serviceName. ");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"The profile '"+aProfile.getLocalName()+"' must specify only one textDescription.");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_INVALID_VALUE,"Profile inputs for service '"+theService.getLocalName()+"' do not match the process inputs!");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_INVALID_VALUE,"Profile outputs for service '"+theService.getLocalName()+"' do not match the process outputs!");
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"Profile '"+aProfile.getLocalName()+"' do not specify a process!");
2ronwalf private void validateServiceParameter(Service theService, ServiceParameter theServiceParameter)
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"Must specify a name for serviceParameter: "+theServiceParameter.getLocalName());
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"Must specify a parameter for serviceParameter: "+theServiceParameter.getLocalName());
2ronwalf private void validateServiceCategory(Service theService, ServiceCategory theServiceCategory)
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"Must specify a code for serviceCategory: "+theServiceCategory.getLocalName());
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"Must specify a value for serviceCategory "+theServiceCategory.getLocalName());
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"Must specify a taxonomy for serviceCategory: "+theServiceCategory.getLocalName());
2ronwalf OWLSValidatorMessage msg = new OWLSValidatorMessage(CODE_MISSING_VALUE,"Must specify a name for serviceCategory: "+theServiceCategory.getLocalName());
7daenzerorama// OWLSValidator aValidator = new OWLSValidator();
2ronwalf// Service aService = kb.readService("http://bai-hu.ethz.ch/next/ont/comp/NMRCompSampleSetup.owl");
2ronwalf// aService.removeProperty(org.mindswap.owls.vocabulary.OWLS_1_1.Service.supports,aService.getGrounding());
2ronwalf// System.err.println(aService.getProperty(org.mindswap.owls.vocabulary.OWLS_1_1.Service.supports));
2ronwalf //new OWLSValidator().validate("http://bai-hu.ethz.ch/next/ont/comp/NMRCompSampleSetup.owl").print(System.err);
2ronwalf //new OWLSValidator().validate(new java.io.File("BookPrice.owl").toURL().toExternalForm().replaceAll(" ","%20")).print(System.err);
2ronwalf //new OWLSValidator().validate("http://www.kellyjoe.com/services/commissioning/CommissioningService.owl").print(System.err);
2ronwalf new OWLSValidator().validate(new java.io.File("composite.owl").toURL().toExternalForm().replaceAll(" ","%20")).print(System.err);
2ronwalf //Service aService = kb.readService("http://www.kellyjoe.com/services/commissioning/CommissioningService.owl");
2ronwalf// Service aService = kb.readService("http://bai-hu.ethz.ch/next/ont/comp/NMRCompSampleSetup.owl");
2ronwalf // this code illustrates the cast exception that arises when getting the service parameters for a profile
2ronwalf// String aURI = "http://www.mindswap.org/2004/owl-s/1.1/sensor/GetData2.owl";
2ronwalf //String aURI = "http://www.mindswap.org/2004/owl-s/1.1/sensor/GetData2.owl";
2ronwalf //String aURI = "http://www.mindswap.org/2004/owl-s/1.1/BNPrice.owl";
2ronwalf //String aURI = "http://www.mindswap.org/2004/owl-s/1.1/BookPrice.owl";
2ronwalf //String aURI = "http://www.mindswap.org/2004/owl-s/1.1/AmazonBookPrice.owl";
2ronwalf //String aURI = "http://www.mindswap.org/2004/owl-s/1.1/BookFinder.owl";
2ronwalf //String aURI = "http://www.mindswap.org/2004/owl-s/1.1/BabelFishTranslator.owl";
2ronwalf//String aURI = "http://www.mindswap.org/2004/owl-s/1.1/CheaperBookFinder.owl";
2ronwalf //String aURI = "http://www.mindswap.org/2004/owl-s/1.1/Dictionary.owl";
2ronwalf //String aURI = "http://www.mindswap.org/2004/owl-s/1.1/CurrencyConverter.owl";
2ronwalf//String aURI = "http://www.mindswap.org/2004/owl-s/1.1/FindCheaperBook.owl";
2ronwalf //String aURI = "http://www.mindswap.org/2004/owl-s/1.1/FindLatLong.owl";
2ronwalf//String aURI = "http://www.mindswap.org/2004/owl-s/1.1/FrenchDictionary.owl";
2ronwalf //String aURI = "http://www.mindswap.org/2004/owl-s/1.1/ZipCodeFinder.owl";