Package org.openengsb.core.api.l10n

Examples of org.openengsb.core.api.l10n.PassThroughStringLocalizer


        assertThat(before, is("42"));
        assertThat(after, is("foo"));
    }

    private AttributeDefinition.Builder newAttribute(String id, String name, String desc) {
        return AttributeDefinition.builder(new PassThroughStringLocalizer()).id(id).name(name).description(desc);
    }
View Full Code Here


    public MethodArgumentPanel(String id, final Argument arg) {
        super(id);
        add(new Label("index", String.format("Argument #%d", arg.getIndex())));
        Class<?> type = arg.getType();
        if (type.isPrimitive() || type.isEnum() || hasStringOnlyConstructor(type)) {
            Builder builder = AttributeDefinition.builder(new PassThroughStringLocalizer());
            MethodUtil.addEnumValues(type, builder);
            builder.id("value").name("value");
            if (type.equals(boolean.class) || type.equals(Boolean.class)) {
                builder.asBoolean();
            }
View Full Code Here

    private ConnectorInstanceFactory factoryMock;

    @Before
    public void setup() throws Exception {
        attrib1 =
            AttributeDefinition.builder(new PassThroughStringLocalizer()).id("a").defaultValue("a_default")
                .name("a_name").build();
        ServiceDescriptor d =
            ServiceDescriptor.builder(new PassThroughStringLocalizer()).implementationType(NullDomainImpl.class)
                .id("a").name("sn").description("sd").attribute(attrib1)
                .build();

        ConnectorProvider provider = createConnectorProviderMock("testconnector", "testdomain");
        when(provider.getDescriptor()).thenReturn(d);
View Full Code Here

                        || !Modifier.isPublic(propertyDescriptor.getWriteMethod().getModifiers())
                        || propertyDescriptor.getName().equals(ModelUtils.MODEL_TAIL_FIELD_NAME)) {
                    continue;
                }
                Builder builder =
                    AttributeDefinition.builder(new PassThroughStringLocalizer()).id(propertyDescriptor.getName())
                        .name(propertyDescriptor.getDisplayName())
                        .description(propertyDescriptor.getShortDescription());
                addEnumValues(propertyDescriptor.getPropertyType(), builder);
                AttributeDefinition a = builder.build();
                attributes.add(a);
View Full Code Here

TOP

Related Classes of org.openengsb.core.api.l10n.PassThroughStringLocalizer

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.