Package org.w3c.tools.resources.serialization

Examples of org.w3c.tools.resources.serialization.AttributeDescription


    {
  if(initialized)
      return;

  RemoteResource rr;
  AttributeDescription b[] = null;
  String s[] = null;
  int nbn = 0;
  boolean authorized;
 
View Full Code Here


  attrs[0] = attr;
  return getValues(attrs)[0];
    }

    protected AttributeDescription lookupAttribute(String name) {
  AttributeDescription attds[] = description.getAttributeDescriptions();
  for (int i = 0 ; i < attds.length ; i++) {
      AttributeDescription ad = attds[i];
      if (ad.getName().equals(name))
    return ad;
  }
  return null;
    }
View Full Code Here

    public Object[] getValues(String attrs[])
  throws RemoteAccessException
    {
  Object values[] = new Object[attrs.length];
  for (int i = 0 ; i < attrs.length ; i++) {
      AttributeDescription ad = lookupAttribute(attrs[i]);
      if (ad != null) {
    values[i] = ad.getValue();
      } else {
    values[i] = null;
      }
  }
  return values;
View Full Code Here

  throws RemoteAccessException
    {
  String  newId  = null;
  boolean change = false;

  AttributeDescription attrs[] = new AttributeDescription[names.length];

  for (int i = 0 ; i < names.length ; i++) {
      AttributeDescription ad = lookupAttribute(names[i]);
      if (ad != null) {
    ad.setValue(values[i]);
    attrs[i] = ad;
      }
      if (names[i].equals("identifier")) {
    change = true;
    newId = (String) values[i];
View Full Code Here

    ((PlainRemoteResource) frames[i]).dump(prt);
      }
  }
  // Run the query, and display results:
  System.out.println("+ attributes: ");
  AttributeDescription attrs[]   = getAttributes();
  for (int i = 0 ; i < attrs.length ; i++) {
      Attribute att = attrs[i].getAttribute();
      if (att.checkFlag(Attribute.EDITABLE)) {
    Object value = attrs[i].getValue();
    if (value != null) {
View Full Code Here

    {
  if(initialized)
      return;

  RemoteResource rr;
  AttributeDescription b[] = null;
  String s[] = null;
  int nbn = 0;
  boolean authorized;
 
View Full Code Here

      Vector vresources = (Vector)resourceSetStack.peek();
      vresources.addElement(res);
  } else if (iname == iATTRIBUTE_TAG) {
      currentS = null;
  } else if (iname == iARRAY_TAG) {
      AttributeDescription ad =
    new AttributeDescription(currentA, currentA.unpickle(array));
      Vector attrs = (Vector)defsStack.peek();
      attrs.addElement(ad);
      currentA = null;
  } else if (iname == iRESARRAY_TAG) {
      Vector vframes = (Vector) resourceSetStack.pop();
      ResourceDescription frames[] =
    new ResourceDescription[vframes.size()];
      vframes.copyInto(frames);
      AttributeDescription ad =
    new AttributeDescription((Attribute)FAStack.pop(),
           frames);
      Vector attrs = (Vector)defsStack.peek();
      attrs.addElement(ad);
  } else if ((iname== iCHILD_TAG) || (iname == iVALUE_TAG)) {
      isavalue = false;
View Full Code Here

      value = characters.toString();
  }
  characters = null;
  charvalue  = null;
  if (currentS != null) {
      AttributeDescription ad = null;
      if (value.equals(NULL))
    ad = new AttributeDescription(currentS, null);
      else
    ad = new AttributeDescription(currentS,
                currentS.unpickle(value));
      Vector attrs = (Vector)defsStack.peek();
      attrs.addElement(ad);
  } else if (isavalue) {
      array[arrayidx++] = value;
View Full Code Here

      startDescription(resource);
      indent();
      closeDescription();
  } else {
      startResource(resource);
      AttributeDescription attrs [] =
    resource.getAttributeDescriptions();
      for (int j = 0 ; j < attrs.length ; j++)
    writeAttributeDescription(attrs[j]);
      indent();
      closeResource();
View Full Code Here

TOP

Related Classes of org.w3c.tools.resources.serialization.AttributeDescription

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.