Examples of ValueConfig


Examples of org.ardverk.dht.config.ValueConfig

  }
 
  public DHTFuture<ValueEntity> get(Contact[] contacts,
      Key key, ValueConfig config) {
   
    ValueConfig cfg = configProvider.get(config);
   
    DHTProcess<ValueEntity> process
      = new ValueResponseHandler(messageDispatcher, contacts,
          routeTable, key, cfg);
    return futureManager.submit(process, cfg);
View Full Code Here

Examples of org.jboss.as.pojo.descriptor.ValueConfig

        joinpoint.setParameters(params);
        return joinpoint;
    }

    private static void configure(BeanInfo beanInfo, Module module, Object bean, PropertyConfig pc, boolean nullify) throws Throwable {
        ValueConfig value = pc.getValue();
        Class<?> clazz = null;
        String type = pc.getType(); // check property
        if (type == null)
            type = value.getType(); // check value
        if (type != null)
            clazz = module.getClassLoader().loadClass(type);

        Method setter = beanInfo.getSetter(pc.getPropertyName(), clazz);
        MethodJoinpoint joinpoint = new MethodJoinpoint(setter);
        ValueConfig param = (nullify == false) ? value : null;
        joinpoint.setParameters(new ValueConfig[]{param});
        joinpoint.setTarget(new ImmediateValue<Object>(bean));
        joinpoint.dispatch();
    }
View Full Code Here

Examples of org.jboss.as.pojo.descriptor.ValueConfig

    }

    public void dispatch(final Object dependency) throws Throwable {
        MethodJoinpoint joinpoint = new MethodJoinpoint(getMethod());
        joinpoint.setTarget(new ImmediateValue<Object>(bean));
        ValueConfig param = new ValueConfig() {
            protected Object getClassValue(Class<?> type) {
                return dependency;
            }
        };
        joinpoint.setParameters(new ValueConfig[]{param});
View Full Code Here

Examples of org.jboss.as.pojo.descriptor.ValueConfig

        joinpoint.setParameters(params);
        return joinpoint;
    }

    private static void configure(BeanInfo beanInfo, Module module, Object bean, PropertyConfig pc, boolean nullify) throws Throwable {
        ValueConfig value = pc.getValue();
        Class<?> clazz = null;
        String type = pc.getType(); // check property
        if (type == null)
            type = value.getType(); // check value
        if (type != null)
            clazz = module.getClassLoader().loadClass(type);

        Method setter = beanInfo.getSetter(pc.getPropertyName(), clazz);
        MethodJoinpoint joinpoint = new MethodJoinpoint(setter);
        ValueConfig param = (nullify == false) ? value : null;
        joinpoint.setParameters(new ValueConfig[]{param});
        joinpoint.setTarget(new ImmediateValue<Object>(bean));
        joinpoint.dispatch();
    }
View Full Code Here

Examples of org.jboss.as.pojo.descriptor.ValueConfig

    }

    public void dispatch(final Object dependency) throws Throwable {
        MethodJoinpoint joinpoint = new MethodJoinpoint(getMethod());
        joinpoint.setTarget(new ImmediateValue<Object>(bean));
        ValueConfig param = new ValueConfig() {
            protected Object getClassValue(Class<?> type) {
                return dependency;
            }
        };
        joinpoint.setParameters(new ValueConfig[]{param});
View Full Code Here

Examples of org.jboss.as.pojo.descriptor.ValueConfig

        joinpoint.setParameters(params);
        return joinpoint;
    }

    private static void configure(BeanInfo beanInfo, Module module, Object bean, PropertyConfig pc, boolean nullify) throws Throwable {
        ValueConfig value = pc.getValue();
        Class<?> clazz = null;
        String type = pc.getType(); // check property
        if (type == null)
            type = value.getType(); // check value
        if (type != null)
            clazz = module.getClassLoader().loadClass(type);

        Method setter = beanInfo.getSetter(pc.getPropertyName(), clazz);
        MethodJoinpoint joinpoint = new MethodJoinpoint(setter);
        ValueConfig param = (nullify == false) ? value : null;
        joinpoint.setParameters(new ValueConfig[]{param});
        joinpoint.setTarget(new ImmediateValue<Object>(bean));
        joinpoint.dispatch();
    }
View Full Code Here

Examples of org.jboss.as.pojo.descriptor.ValueConfig

    }

    public void dispatch(final Object dependency) throws Throwable {
        MethodJoinpoint joinpoint = new MethodJoinpoint(getMethod());
        joinpoint.setTarget(new ImmediateValue<Object>(bean));
        ValueConfig param = new ValueConfig() {
            protected Object getClassValue(Class<?> type) {
                return dependency;
            }
        };
        joinpoint.setParameters(new ValueConfig[]{param});
View Full Code Here

Examples of org.jboss.as.pojo.descriptor.ValueConfig

            }
        }
    }

    protected void configure(PropertyConfig pc, boolean nullify) throws Throwable {
        ValueConfig value = pc.getValue();
        Class<?> clazz = null;
        String type = pc.getType(); // check property
        if (type == null)
            type = value.getType(); // check value
        if (type != null)
            clazz = getModule().getClassLoader().loadClass(type);

        Method setter = getBeanInfo().getSetter(pc.getPropertyName(), clazz);
        MethodJoinpoint joinpoint = new MethodJoinpoint(setter);
        ValueConfig param = (nullify == false) ? value : null;
        joinpoint.setParameters(new ValueConfig[]{param});
        joinpoint.setTarget(new ImmediateValue<Object>(getBean()));
        joinpoint.dispatch();
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.