Search in sources :

Example 11 with NoSuchPropertyException

use of jp.ossc.nimbus.beans.NoSuchPropertyException in project nimbus by nimbus-org.

the class MappedPropertyTest method testParse2.

public void testParse2() throws Exception {
    MappedProperty prop = new MappedProperty();
    prop.parse("mapped2(fuga)");
    Test test = new Test();
    try {
        prop.setProperty(test, "hoge");
        fail();
    } catch (NoSuchPropertyException e) {
    }
}
Also used : MappedProperty(jp.ossc.nimbus.beans.MappedProperty) NoSuchPropertyException(jp.ossc.nimbus.beans.NoSuchPropertyException)

Example 12 with NoSuchPropertyException

use of jp.ossc.nimbus.beans.NoSuchPropertyException in project nimbus by nimbus-org.

the class SimplePropertyTest method testParse3.

public void testParse3() throws Exception {
    SimpleProperty prop = new SimpleProperty();
    prop.parse("simple2");
    Test test = new Test();
    try {
        prop.getProperty(test);
        fail();
    } catch (NoSuchPropertyException e) {
    }
}
Also used : NoSuchPropertyException(jp.ossc.nimbus.beans.NoSuchPropertyException) SimpleProperty(jp.ossc.nimbus.beans.SimpleProperty)

Example 13 with NoSuchPropertyException

use of jp.ossc.nimbus.beans.NoSuchPropertyException in project nimbus by nimbus-org.

the class IndexedPropertyTest method testParse2.

public void testParse2() throws Exception {
    IndexedProperty prop = new IndexedProperty();
    prop.parse("indexed2[1]");
    Test test = new Test();
    try {
        prop.setProperty(test, "hoge");
        fail();
    } catch (NoSuchPropertyException e) {
    }
}
Also used : IndexedProperty(jp.ossc.nimbus.beans.IndexedProperty) NoSuchPropertyException(jp.ossc.nimbus.beans.NoSuchPropertyException)

Example 14 with NoSuchPropertyException

use of jp.ossc.nimbus.beans.NoSuchPropertyException in project nimbus by nimbus-org.

the class IndexedPropertyTest method testParse3.

public void testParse3() throws Exception {
    IndexedProperty prop = new IndexedProperty();
    prop.parse("indexed2[1]");
    Test test = new Test();
    try {
        prop.getProperty(test);
        fail();
    } catch (NoSuchPropertyException e) {
    }
}
Also used : IndexedProperty(jp.ossc.nimbus.beans.IndexedProperty) NoSuchPropertyException(jp.ossc.nimbus.beans.NoSuchPropertyException)

Example 15 with NoSuchPropertyException

use of jp.ossc.nimbus.beans.NoSuchPropertyException in project nimbus by nimbus-org.

the class WrappedClientConnectionFactoryService method getClientConnection.

public ClientConnection getClientConnection() throws ConnectionCreateException, RemoteException {
    if (getState() != STARTED) {
        throw new ConnectionCreateException("Service not started. name=" + getServiceNameObject());
    }
    try {
        ClientConnection clientConnection = (ClientConnection) clientConnectionWrapperConstructor.newInstance(new Object[] { clientConnectionFactory.getClientConnection() });
        if (properties != null) {
            final Iterator props = properties.keySet().iterator();
            while (props.hasNext()) {
                final Property prop = (Property) props.next();
                final Object val = properties.get(prop);
                prop.setProperty(clientConnection, val);
            }
        }
        return clientConnection;
    } catch (IllegalAccessException e) {
        throw new ConnectionCreateException(e);
    } catch (InstantiationException e) {
        throw new ConnectionCreateException(e);
    } catch (InvocationTargetException e) {
        throw new ConnectionCreateException(e);
    } catch (NoSuchPropertyException e) {
        throw new ConnectionCreateException(e);
    }
}
Also used : NoSuchPropertyException(jp.ossc.nimbus.beans.NoSuchPropertyException) Property(jp.ossc.nimbus.beans.Property) InvocationTargetException(java.lang.reflect.InvocationTargetException)

Aggregations

NoSuchPropertyException (jp.ossc.nimbus.beans.NoSuchPropertyException)27 InvocationTargetException (java.lang.reflect.InvocationTargetException)18 Map (java.util.Map)13 HashMap (java.util.HashMap)11 Iterator (java.util.Iterator)11 Property (jp.ossc.nimbus.beans.Property)8 RecordList (jp.ossc.nimbus.beans.dataset.RecordList)7 LinkedHashMap (java.util.LinkedHashMap)6 List (java.util.List)6 ArrayList (java.util.ArrayList)5 NestedProperty (jp.ossc.nimbus.beans.NestedProperty)5 SQLException (java.sql.SQLException)4 SimpleProperty (jp.ossc.nimbus.beans.SimpleProperty)4 DataSet (jp.ossc.nimbus.beans.dataset.DataSet)4 Record (jp.ossc.nimbus.beans.dataset.Record)4 ParameterMetaData (java.sql.ParameterMetaData)3 ResultSet (java.sql.ResultSet)3 ResultSetMetaData (java.sql.ResultSetMetaData)3 IndexedProperty (jp.ossc.nimbus.beans.IndexedProperty)3 PropertyEditor (java.beans.PropertyEditor)2