def licenseValidation(self): """ """ self.licenseKey = self.licenseKeyDialog() if self.licenseKey: licenseObj = License.License(self.licenseKey) self.validator = licenseObj.validate() if self.validator == 'Invalid': print("Invalid License") self.licenseValidation() elif self.validator == 'Expired': print("License Expired") self.licenseValidation() elif self.validator == 'Valid': License.License.writeLicense(self.licenseKey)
def parse_study_file(self): experiment = Study.Study() self.experiment = URIRef(self.graph.reproduce['Experiment' + '_' + self.study_number]) self.g.add((self.experiment, RDF.type, URIRef(self.graph.reproduce["Experiment"]))) self.parse(self.experiment, experiment.mapping) self.imaging_study = URIRef(self.graph.reproduce['ImagingStudy' + '_' + self.study_number]) self.g.add((self.imaging_study, RDF.type, URIRef(self.graph.reproduce["ImagingStudy"]))) agent = Agent.Agent() self.parse_agent(agent.mapping) license = License.License() self.license = URIRef(self.graph.reproduce['License' + '_' + self.study_number]) self.g.add( (self.license, RDF.type, URIRef(self.graph.reproduce["License"]))) self.parse(self.license, license.mapping) publication = Publication.Publication() self.publication = URIRef(self.graph.reproduce['Publication' + '_' + self.study_number]) self.g.add((self.publication, RDF.type, URIRef(self.graph.reproduce["Publication"]))) self.parse(self.publication, publication.mapping) organism = Organism.Organism() self.organism = URIRef(self.graph.reproduce['Organism' + '_' + self.study_number]) self.g.add((self.organism, RDF.type, URIRef(self.graph.reproduce["Organism"]))) self.parse(self.organism, organism.mapping) self.parse_screen() self.parse_assay()