Package scap.check.content

Examples of scap.check.content.XmlBeansInstance


  public TailoringDocumentImpl(SourceContext tailoringSourceContext, SourceContext documentSourceContext) throws XmlException, IOException {
    super(documentSourceContext);
    this.sourceContext = tailoringSourceContext;

    SourceContent sourceContent = sourceContext.getSourceContent();
    XmlBeansInstance xmlBeansInstance = sourceContent.getXmlBeansInstance();
    if (xmlBeansInstance.isDocumentType()) {
      this.data = ((TailoringDocument)xmlBeansInstance.getXmlObject().copy()).getTailoring();
    } else {
      this.data = (TailoringType)xmlBeansInstance.getXmlObject().copy();
    }

    // Parse Profiles
    List<ProfileType> profiles = data.getProfileList();
    for (ProfileType node : profiles) {
View Full Code Here


    private final OvalDefinitionsDocument.OvalDefinitions document;
    private final Map<String, ExternalVariable> variables;
    private final Map<String, DefinitionType> definitions;
   
    public OVALResolver(SourceContent ovalDefinitionFile) throws XmlException, IOException {
      XmlBeansInstance xmlBeansInstance = ovalDefinitionFile.getXmlBeansInstance();
      if (xmlBeansInstance.isDocumentType()) {
        document = ((OvalDefinitionsDocument)xmlBeansInstance.getXmlObject()).getOvalDefinitions();
      } else {
        document = (OvalDefinitionsDocument.OvalDefinitions)xmlBeansInstance.getXmlObject();
      }

      if (document.isSetVariables()) {
        List<VariableType> data = document.getVariables().getVariableList();
        variables = new HashMap<String, ExternalVariable>(data.size());
View Full Code Here

    Map<ItemType, GroupType> parentMap = new HashMap<ItemType, GroupType>();

  public XCCDFDocumentImpl(SourceContext sourceContext) throws XmlException, IOException {
    super(sourceContext);
    SourceContent sourceContent = sourceContext.getSourceContent();
    XmlBeansInstance xmlBeansInstance = sourceContent.getXmlBeansInstance();
    if (xmlBeansInstance.isDocumentType()) {
      this.data = ((BenchmarkDocument)xmlBeansInstance.getXmlObject().copy()).getBenchmark();
    } else {
      this.data = (Benchmark)xmlBeansInstance.getXmlObject().copy();
    }

    log.info("Parsing checklist: "+sourceContent.getId());
    // Parse CPE Applicability Statements
    if (data.isSetPlatformSpecification()) {
View Full Code Here

  public XCCDFDocumentImpl(SourceContext sourceContext) throws XmlException, IOException {
    super(sourceContext);

    SourceContent sourceContent = sourceContext.getSourceContent();
    XmlBeansInstance xmlBeansInstance = sourceContent.getXmlBeansInstance();
    if (xmlBeansInstance.isDocumentType()) {
      this.data = ((BenchmarkDocument)xmlBeansInstance.getXmlObject().copy()).getBenchmark();
    } else {
      this.data = (Benchmark)xmlBeansInstance.getXmlObject().copy();
    }

    log.info("parsing checklist "+sourceContent.getId());
    // Parse CPE Applicability Statements
    if (data.isSetPlatformSpecification2()) {
View Full Code Here

TOP

Related Classes of scap.check.content.XmlBeansInstance

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.