Package com.sun.star.beans

Examples of com.sun.star.beans.Property


                return props;
            }

            public boolean hasPropertyByName(String name) {
                for (int i = 0; i < props.length; i++) {
                    Property prop = props[i];

                    if (prop.Name.equals(name)) {
                        return true;
                    }
                }

                return false;
            }

            public Property getPropertyByName(String name) throws UnknownPropertyException {
                for (int i = 0; i < props.length; i++) {
                    Property prop = props[i];

                    if (prop.Name.equals(name)) {
                        return prop;
                    }
                }
View Full Code Here


    public static void printPropertyInfo(XPropertySet PS, String name,
                                                        PrintWriter out) {
        try {
            XPropertySetInfo PSI = PS.getPropertySetInfo();
            Property[] props = PSI.getProperties();
            Property prop = PSI.getPropertyByName(name);
            out.println("Property name is " + prop.Name);
            out.println("Property handle is " + prop.Handle);
            out.println("Property type is " + prop.Type.getTypeName());
            out.println("Property current value is " +
                                                    PS.getPropertyValue(name));
View Full Code Here

        String propertyName, Object oldValue, Object newValue,
        BoundListeners bound)
        throws PropertyVetoException
    {
        // assert properties.get(propertyName) != null;
        Property p = ((PropertyData) properties.get(propertyName)).property;
        Vector specificVeto = null;
        Vector unspecificVeto = null;
        synchronized (this) {
            if (disposed) {
                throw new DisposedException("disposed", object);
View Full Code Here

                        }
                    }
                    if (map.put(
                            name,
                            new PropertyData(
                                new Property(
                                    name, handleNames.size(),
                                    new Type(t.getName(), t.getTypeClass()),
                                    attrAttribs),
                                present))
                        != null)
View Full Code Here

     @param attributes The property's attributes (Property.Attributes).
     *  @param id Identifies the property's storage.
     */
    protected void registerProperty(String name, int handle, Type type, short attributes, Object id)
    {
        Property p= new Property(name, handle, type, attributes);
        registerProperty(p, id);
    }
View Full Code Here

     @param attributes The property's attributes (Property.Attributes).
     *  @param id Identifies the property's storage.
     */
    protected void registerProperty(String name, Type type, short attributes, Object id)
    {
        Property p= new Property(name, lastHandle++, type, attributes);
        registerProperty(p, id);
    }
View Full Code Here

        }
        Class cl= propField.getType();
        Type t= new Type(cl);
        if (t.getTypeClass() != TypeClass.UNKNOWN)
        {
            Property p= new Property(propertyName, lastHandle++,  t, attributes);
            registerProperty(p,memberName);
        }
        else
            throw new com.sun.star.uno.RuntimeException("the member has an unknown type: " + memberName);
    }
View Full Code Here

      // only add listeners if you are not disposed
        if (! bInDispose && ! bDisposed)
        {
            if (str.length() > 0)
            {
                Property prop= getProperty(str);
                if (prop == null)
                    throw new UnknownPropertyException("Property " + str + " is unknown");

                // Add listener for a certain property
                if ((prop.Attributes & PropertyAttribute.BOUND) > 0)
View Full Code Here

     // only add listeners if you are not disposed
        if (! bInDispose && ! bDisposed)
        {
            if (str.length() > 0)
            {
                Property prop= getProperty(str);
                if (prop == null)
                    throw new UnknownPropertyException("Property " + str + " is unknown");

                // Add listener for a certain property
                if ((prop.Attributes & PropertyAttribute.CONSTRAINED) > 0)
View Full Code Here

    {  
        Object ret= null;
        if (bInDispose || bDisposed)
            throw new com.sun.star.lang.DisposedException("The component has been disposed already");
        Property prop= getProperty(name);
        if (prop == null)
            throw new UnknownPropertyException("The property " + name + " is unknown");
       
        synchronized (this)
        {
View Full Code Here

TOP

Related Classes of com.sun.star.beans.Property

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.