Package fr.norsys.mapper.console.model

Examples of fr.norsys.mapper.console.model.AttributeNameComparator


 
  public void test01Get(){
    if(log.isDebugEnabled()) log.debug("*** test01Get ***");
    List applications = new ArrayList();
    Collection resources =new  TreeSet(new ResourceNameComparator());
    Collection attributes = new TreeSet(new AttributeNameComparator());
    Attribute attribute = new Attribute("test");
    String currentAttribute = attribute.getId();
    Resource resource = new Resource("test");
    Application application = new Application("test");
    attributes.add(attribute);
View Full Code Here


 
  public void test01Modify() throws Exception {
    if(log.isDebugEnabled()) log.debug("*** test01Modify ***");
    List applications = new ArrayList();
    Collection resources =new  TreeSet(new ResourceNameComparator());
    Collection attributes = new TreeSet(new AttributeNameComparator());
    Attribute attribute = new Attribute("attribute");
    String currentAttribute = attribute.getId();
    Resource resource = new Resource("test");
    String currentResource = resource.getId();
    Application application = new Application("test");
View Full Code Here

   * action to delete an attribute from the attributes list of the resource
   * @param currentAttributeId : id of the current attribute
   * @param currentResource : resource bean
   */
  public void deleteAttr(String currentAttrId, Resource currentResource) {
    Collection tempAttributes = new TreeSet(new AttributeNameComparator());
    for(Iterator attributes=currentResource.getAttributes().iterator(); attributes.hasNext();){
      Attribute attr =(Attribute)attributes.next();
      if(!attr.getId().equals(currentAttrId)){
        tempAttributes.add(attr);
      }
View Full Code Here

    String currentResource = resource.getId();
    resources.add(resource);
   
    Resource resource2 = new Resource("test2");
    String currentResource2 = resource2.getId();
    Collection attributes =new  TreeSet(new AttributeNameComparator());
    Attribute attribute = new Attribute("test");
    attributes.add(attribute);
    resource2.setAttributes(attributes);
    resources.add(resource2);
    Application application = new Application("test");
View Full Code Here

 
  public void test01deleteAttr() throws Exception {
    if(log.isDebugEnabled()) log.debug("*** test01deleteAttr ***");
    List applications = new ArrayList();
    Collection resources =new  TreeSet(new ResourceNameComparator());
    Collection attributes = new TreeSet(new AttributeNameComparator());
    Attribute attribute = new Attribute("test");
    String currentAttribute = attribute.getId();
    Resource resource = new Resource("test");
    String currentResource = resource.getId();
    Application application = new Application("test");
View Full Code Here

TOP

Related Classes of fr.norsys.mapper.console.model.AttributeNameComparator

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.