Package buri.ddmsence.ddms.resource

Examples of buri.ddmsence.ddms.resource.Dates


  private URL buildDateGraph() throws IOException {
    Distribution distribution = new Distribution();
    for (Resource resource : getResources()) {
      // Examine the ddms:dates element (optional field with optional attributes)
      // Ignores ddms:DateHourMinType dates, which were introduced in DDMS 4.1, to simplify example
      Dates dates = resource.getDates();
      if (dates != null) {
        if (dates.getCreated() != null)
          distribution.incrementCount(String.valueOf(dates.getCreated().getYear()));
        if (dates.getPosted() != null)
          distribution.incrementCount(String.valueOf(dates.getPosted().getYear()));
        if (dates.getValidTil() != null)
          distribution.incrementCount(String.valueOf(dates.getValidTil().getYear()));
        if (dates.getInfoCutOff() != null)
          distribution.incrementCount(String.valueOf(dates.getInfoCutOff().getYear()));
        if (dates.getApprovedOn() != null)
          distribution.incrementCount(String.valueOf(dates.getApprovedOn().getYear()));
        if (dates.getReceivedOn() != null)
          distribution.incrementCount(String.valueOf(dates.getReceivedOn().getYear()));
      }

      // Resource createDate (required field in 3.0, 4.0.1, and 4.1, optional in 2.0)
      if (resource.getCreateDate() != null)
        distribution.incrementCount(String.valueOf(resource.getCreateDate().getYear()));
View Full Code Here


        String posted = readString("the posted date [2010]");
        String validTil = readString("the validTil date [2010]");
        String infoCutOff = readString("the infoCutOff date [2010]");
        String approvedOn = readString("the approvedOn date [2010]");
        String receivedOn = readString("the receivedOn date [2010]");
        return (new Dates(null, created, posted, validTil, infoCutOff, approvedOn, receivedOn));
      }
    });
    CONSTRUCTOR_BUILDERS.put(AbstractProducerRole.class, new IConstructorBuilder() {
      public IDDMSComponent build() throws IOException, InvalidDDMSException {
        DDMSVersion version = DDMSVersion.getCurrentVersion();
View Full Code Here

      components = element.getChildElements(Language.getName(version), namespace);
      for (int i = 0; i < components.size(); i++)
        _languages.add(new Language(components.get(i)));
      component = getChild(Dates.getName(version));
      if (component != null)
        _dates = new Dates(component);
      component = getChild(Rights.getName(version));
      if (component != null)
        _rights = new Rights(component);
      components = element.getChildElements(Source.getName(version), namespace);
      for (int i = 0; i < components.size(); i++)
View Full Code Here

      for (int i = 0; i < components.size(); i++) {
        _identifiers.add(new Identifier(components.get(i)));
      }
      Element component = element.getFirstChildElement(Dates.getName(version), getNamespace());
      if (component != null)
        _dates = new Dates(component);
      components = element.getChildElements(Creator.getName(version), getNamespace());
      for (int i = 0; i < components.size(); i++)
        _creators.add(new Creator(components.get(i)));
      components = element.getChildElements(Publisher.getName(version), getNamespace());
      for (int i = 0; i < components.size(); i++)
View Full Code Here

TOP

Related Classes of buri.ddmsence.ddms.resource.Dates

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.