Package Framework

Examples of Framework.TextData


            this.open = true;
        } catch (LDAPException e) {
            throw new RemoteAccessException(
                    "Failed to to connect on this object"); // As thrown by UDS
        }
        return new TextData("open"); // As returned by UDS
    }
View Full Code Here


    public TextData bind(int pMessageID, TextData pName, TextData pPassword,int pVersion) {
        return this.bind(pMessageID,pName,pPassword);
    }

    public TextData bind(int pMessageID, TextData pName, TextData pPassword) {
        TextData returnString = new TextData("success"); // As returned by
        // UDS
        try {
            this.connection.bind(com.novell.ldap.LDAPConnection.LDAP_V3, pName
                    .toString(), pPassword.toString().getBytes());
        } catch (LDAPException e) {
            if (e.getResultCode() == LDAPException.INVALID_CREDENTIALS) {
                returnString = new TextData("invalidCredentials"); // As
                // returned
                // by UDS
            }
        }
        return returnString;
View Full Code Here

        return returnString;
    }

    public TextData unbind(int pMessageID) {
        this.close();
        return new TextData("Connection closed"); // As returned by UDS
    }
View Full Code Here

            pResults.setObject(results);
        } catch (LDAPException e) {
            e.printStackTrace();
        }

        return new TextData("success"); // As returned by UDS
    }
View Full Code Here

  public TextData search(int pMessageID, TextData pBase, int pScope,
            int pDerefAliases, int pSizeLimit, int pTimeLimit,
            boolean pTypesOnly, LDAPFilter pFilter,
            Array_Of_TextData<TextData> pAttributes, ParameterHolder_LDAPEntry_Array pResults) {

        TextData returnString = new TextData("success"); // As returned by
        // UDS

        LDAPSearchResults results;

        try {
            results = this.ldapSearch(pBase, pScope, pDerefAliases,
                    pSizeLimit, pTimeLimit, pTypesOnly, pFilter, pAttributes);
            org.ietf.ldap.LDAPEntry entry;
            org.ietf.ldap.LDAPAttribute attribute;
            LDAPAttributeSet attrSet;
            LDAP.LDAPEntry fEntry;
            LDAP.LDAPAttribute fAttribute;
            Iterator<org.ietf.ldap.LDAPAttribute> setItr;
            Array_Of_TextData<TextData> listOfTextDataValues;
            String[] listOfStringValues;
            Array_Of_LDAPAttribute<LDAPAttribute> listOfAttributes;
            while (results.hasMore()) {
                entry = (org.ietf.ldap.LDAPEntry)(results.next());
                fEntry = new LDAP.LDAPEntry();
                fEntry.setDN(entry.getDN());
                listOfAttributes = new Array_Of_LDAPAttribute<LDAPAttribute>();
                attrSet = entry.getAttributeSet();
                setItr = attrSet.iterator();
                while (setItr.hasNext()) {
                    attribute = (org.ietf.ldap.LDAPAttribute)setItr.next();
                    fAttribute = new LDAP.LDAPAttribute();
                    fAttribute.setAttName(new TextData(attribute.getName()));
                    listOfStringValues = attribute.getStringValueArray();
                    listOfTextDataValues = new Array_Of_TextData<TextData>();
                    for (int j=0, jSize = listOfStringValues.length; j<jSize; j++ ) {
                        listOfTextDataValues.add(new TextData(listOfStringValues[j]));
                    }
                    fAttribute.setAttValueList(listOfTextDataValues);
                    listOfAttributes.add(fAttribute);
                }
                fEntry.setAttList(listOfAttributes);
                ((Array_Of_LDAPEntry<LDAPEntry>)pResults.getObject()).add(fEntry);
            }
        } catch (LDAPException e) {
            if (pSizeLimit >0) {
                returnString = new TextData("sizeLimitExceeded")// As return by UDS
            } else {
                returnString = new TextData("failed");
            }
        }

        return returnString;
    }
View Full Code Here

        this.visibleColumns = visibleColumns;
    }
   
    //PM:14/3/08 properties for binding the edited value
    public void setEditedValue(String value){
      setTextValue(new TextData(value));
    }
View Full Code Here

     */
    public static Document newDocument(MemoryStream stream) {
        try {
            DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
            DocumentBuilder builder = factory.newDocumentBuilder();
            TextData fullXML = new TextData();
            TextData lineXML = new TextData();
           
            stream.open(Constants.SP_AM_READ);

            while (stream.readLine(lineXML) != -1) {
              fullXML.concat(lineXML);
View Full Code Here

      clearCache(e);
    }
  };

  private void clearCache(JFrame frame) {
    TextData statusTextDataObject = (TextData)UIutils.getForm(frame).getClientProperty(cSTATUS_WIDGET);
      if (statusTextDataObject != null) {
      statusTextDataObject.removePropertyChangeListener("value", oldValueChangeListener);
      oldValueCache.remove(statusTextDataObject);
    }
  }
View Full Code Here

    private StatusTextListener(){
    }

    public void mouseEntered(MouseEvent e) {
        TextData statusTextValue = (TextData)((JComponent)e.getSource()).getClientProperty(StatusText.cSTATUS_TEXT);
        // TF:01/03/2010:DET-130:Check to see if the value is null
      setStatusTextForComponent((JComponent)e.getSource(), statusTextValue);
    }
View Full Code Here

     * @param component the component inside of the window.
     * @param statusTextValue the status text value.
     */
  public void setStatusTextForComponent(JComponent component, TextData statusTextValue) {
    JFrame topLevelAncestor = (JFrame)component.getTopLevelAncestor();
        TextData mappedProperty = (TextData)UIutils.getForm(topLevelAncestor).getClientProperty(cSTATUS_WIDGET);
       
    if (mappedProperty != null){
      if (!oldValueCache.containsKey(mappedProperty)) {
        oldValueCache.put(mappedProperty, mappedProperty.toString());
         
        mappedProperty.addPropertyChangeListener("value", oldValueChangeListener);
        // TF:01/03/2010:Ensure we're only in the cache once, even if the status text field is changed
        topLevelAncestor.removeWindowListener(windowClosingListener);
        topLevelAncestor.addWindowListener(windowClosingListener);
      }
      // TF:01/03/2010:Always update the old value in the cache, as the mouse exit handler will expect a valid value
      oldValueCache.put(mappedProperty, mappedProperty.toString());
      if (statusTextValue != null) {
        setStatusText(mappedProperty, statusTextValue.toString());
      }
        }
  }
View Full Code Here

TOP

Related Classes of Framework.TextData

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.