Examples of removeProperties()


Examples of com.hp.hpl.jena.rdf.model.Resource.removeProperties()

    Model model = target.getModel();
    Resource permissionsAlternatives;
    if (requiredPermssionStmt != null) {
      permissionsAlternatives = requiredPermssionStmt.getResource();
      target.removeAll(AUTHORIZATION.requires);
      permissionsAlternatives.removeProperties();
      permissionsAlternatives.addProperty(RDF.type,
          AUTHORIZATION.PermissionAlternatives);
    } else {
      permissionsAlternatives = model
          .createResource(AUTHORIZATION.PermissionAlternatives);
View Full Code Here

Examples of com.hp.hpl.jena.rdf.model.Resource.removeProperties()

        delete = "delete".equals(body.getParameterValues("delete")[0]);
      } catch (Exception ex) {
      }

      if (delete) {
        user.removeProperties();
        new org.wymiwyg.rwcf.util.EnhancedResponse(response)
            .sendRedirect("/admin/user_manager");
        return;
      }
      user.removeAll(AUTHORIZATION.password);
View Full Code Here

Examples of com.hp.hpl.jena.rdf.model.Resource.removeProperties()

    if ("change".equals(action)) {
      Resource languageRes = getLanguageResource(abbreviation);
      if (languageRes == null) {
        throw new HandlerException("Language with that abbreviation does not exist");
      }
      languageRes.removeProperties();
      setPropertiesOn(languageRes, body);
    }
 
  }
 
View Full Code Here

Examples of com.hp.hpl.jena.rdf.model.Resource.removeProperties()

      handlers.add(iter.nextResource());
    }
    iter.close();
    for (Iterator iterator = handlers.iterator(); iterator.hasNext();) {
      Resource current = (Resource) iterator.next();
      current.removeProperties();
    }
    iter.close();
  }

  /**
 
View Full Code Here

Examples of com.hp.hpl.jena.rdf.model.Resource.removeProperties()

    Model importing = ModelFactory.createDefaultModel();
    importing.read(new StringReader(serializedModel), ehRequest
        .getRequestURLWithoutParams().toString(), "RDF/XML")
    if (codeOrig != null) {
      Resource resOrig = getCountryByCode(codeOrig);
      resOrig.removeProperties();
    }
    ResIterator importCountryIter = importing.listSubjectsWithProperty(RDF.type, POSTADDRESS.Country);
    while (importCountryIter.hasNext()) {
      importCountry(importCountryIter.nextResource());
    }
View Full Code Here

Examples of com.hp.hpl.jena.rdf.model.Resource.removeProperties()

   * @param resource
   */
  private void importCountry(Resource country) {
    String code = country.getProperty(POSTADDRESS.countryCode).getString();
    Resource oldVersion = getCountryByCode(code);
    oldVersion.removeProperties();
    model.add(JenaUtil.getExpandedResource(country, 2));
  }

  /**
   * @param codeOrig
View Full Code Here

Examples of com.hp.hpl.jena.rdf.model.Resource.removeProperties()

        relationTarget);
    while (relations.hasNext()) {
      Resource current = relations.nextResource();
      if (current.hasProperty(KNOBOT.source, relationSource)) {
        RelationManager.removeRelation(current);
        current.removeProperties();
      } else {
        log.debug("Resource unequal: "
            + current.getProperty(KNOBOT.source).getResource()
            + " ," + relationSource);
      }
View Full Code Here

Examples of com.hp.hpl.jena.rdf.model.Resource.removeProperties()

    Resource aggregated = model.createResource(aggregatedURL);
    ResIterator aggregations = model.listSubjectsWithProperty(
        AGGREGATOR.aggregated, aggregated);
    while (aggregations.hasNext()) {
      Resource current = aggregations.nextResource();
      current.removeProperties();
    }
    if (!stop) {
      int interval = Integer.parseInt(body.getParameter("interval"));
      Resource newAggregator = model.createResource(AGGREGATOR.Aggregator);
      newAggregator.addProperty(AGGREGATOR.aggregated, aggregated);
View Full Code Here

Examples of com.hp.hpl.jena.rdf.model.Resource.removeProperties()

    relations.remove(supposedBestRelation);
    out.println("keeping "+supposedBestRelation);
    for (Iterator iter = relations.iterator(); iter.hasNext();) {
      Resource current = (Resource) iter.next();
      out.println("removing "+current);
      current.removeProperties();
    }
  }

  /**
   * @param current
View Full Code Here

Examples of com.hp.hpl.jena.rdf.model.Resource.removeProperties()

            try {
              removeRelation(current);
            } catch (Exception ex1) {
              log.warn("could not reconnect surroundings");
            }
            current.removeProperties();
            model.remove(model.listStatements(new SimpleSelector(null, null, current)));
          }
        }
      } 
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.