Package com.sonyericsson.hudson.plugins.metadata.model

Examples of com.sonyericsson.hudson.plugins.metadata.model.MetadataJobProperty$MetaDataJobPropertyDescriptor


        if (item instanceof AbstractProject) {
            AbstractProject project = (AbstractProject)item;
            JobProperty metadataJobProperty = project.getProperty(MetadataJobProperty.class);
            if (metadataJobProperty == null) {
                try {
                    project.addProperty(new MetadataJobProperty());
                } catch (IOException e) {
                    logger.info("Could not create initial MetadataJobProperty for " + project.getName());
                }
            }
        }
View Full Code Here


     *
     * @throws Exception if so.
     */
    @Test
    public void testAddStringValueToJobProperty() throws Exception {
        MetadataJobProperty root = new MetadataJobProperty();
        boolean result = TreeStructureUtil.addValue(root, "value", "description", "one", "two");
        assertTrue(result);
        TreeNodeMetadataValue one = (TreeNodeMetadataValue)root.getChild("one");
        assertNotNull(one);
        assertSame(root, one.getParent());
        Metadata two = one.getChild("two");
        assertNotNull(two);
        assertSame(one, two.getParent());
View Full Code Here

        List<MetadataValue> list = new LinkedList<MetadataValue>();
        StringMetadataValue name = new StringMetadataValue("name", "description", "somc");
        StringMetadataValue dept = new StringMetadataValue("dept", "description", "tool");
        list.add(name);
        list.add(dept);
        MetadataJobProperty property = project.getProperty(MetadataJobProperty.class);
        property.addChildren(list);
        list = new LinkedList<MetadataValue>();
        name = new StringMetadataValue("name", "description", "somc");
        list.add(name);
        MetadataJobProperty property2 = project2.getProperty(MetadataJobProperty.class);
        property2.addChildren(list);
        MetadataQuerySearch mqs = MetadataQuerySearch.parseQuery("name=somc && dept=tool");
        TopLevelItem tli1 = project;
        TopLevelItem tli2 = project2;
        List itemList = new ArrayList();
        itemList.add(tli1);
View Full Code Here

        List<MetadataValue> list = new LinkedList<MetadataValue>();
        StringMetadataValue name = new StringMetadataValue("name", "description", "somc");
        StringMetadataValue dept = new StringMetadataValue("dept", "description", "tool");
        list.add(name);
        list.add(dept);
        MetadataJobProperty property = project.getProperty(MetadataJobProperty.class);
        property.addChildren(list);
        list = new LinkedList<MetadataValue>();
        name = new StringMetadataValue("name", "description", "somc");
        list.add(name);
        MetadataJobProperty property2 = project2.getProperty(MetadataJobProperty.class);
        property2.addChildren(list);
        MetadataQuerySearch mqs = MetadataQuerySearch.parseQuery("name=somc || dept=tool");
        TopLevelItem tli1 = project;
        TopLevelItem tli2 = project2;
        List itemList = new ArrayList();
        itemList.add(tli1);
View Full Code Here

        List<MetadataValue> list = new LinkedList<MetadataValue>();
        StringMetadataValue name = new StringMetadataValue("name", "description", "somc");
        StringMetadataValue dept = new StringMetadataValue("dept", "description", "tool");
        list.add(name);
        list.add(dept);
        MetadataJobProperty property = project.getProperty(MetadataJobProperty.class);
        property.addChildren(list);
        list = new LinkedList<MetadataValue>();
        name = new StringMetadataValue("name", "description", "somc");
        list.add(name);
        MetadataJobProperty property2 = project2.getProperty(MetadataJobProperty.class);
        property2.addChildren(list);
        MetadataQuerySearch mqs = MetadataQuerySearch.parseQuery("dept=tool");
        TopLevelItem tli1 = project;
        TopLevelItem tli2 = project2;
        List itemList = new ArrayList();
        itemList.add(tli1);
View Full Code Here

        FreeStyleProject project = createFreeStyleProject("open");
        FreeStyleProject project2 = createFreeStyleProject("secure");
        List<MetadataValue> list = new LinkedList<MetadataValue>();
        NumberMetadataValue number = new NumberMetadataValue("number", "description", NUMBR_VAL1, false);
        list.add(number);
        MetadataJobProperty property = project.getProperty(MetadataJobProperty.class);
        property.addChildren(list);
        list = new LinkedList<MetadataValue>();
        number = new NumberMetadataValue("number", "description", NUMBR_VAL2, false);
        list.add(number);
        MetadataJobProperty property2 = project2.getProperty(MetadataJobProperty.class);
        property2.addChildren(list);
        MetadataQuerySearch mqs = MetadataQuerySearch.parseQuery("number>=5");
        TopLevelItem tli1 = project;
        TopLevelItem tli2 = project2;
        List itemList = new ArrayList();
        itemList.add(tli1);
View Full Code Here

        FreeStyleProject project = createFreeStyleProject("open");
        FreeStyleProject project2 = createFreeStyleProject("secure");
        List<MetadataValue> list = new LinkedList<MetadataValue>();
        NumberMetadataValue number = new NumberMetadataValue("number", "description", NUMBR_VAL1, false);
        list.add(number);
        MetadataJobProperty property = project.getProperty(MetadataJobProperty.class);
        property.addChildren(list);
        list = new LinkedList<MetadataValue>();
        number = new NumberMetadataValue("number", "description", NUMBR_VAL2, false);
        list.add(number);
        MetadataJobProperty property2 = project2.getProperty(MetadataJobProperty.class);
        property2.addChildren(list);
        MetadataQuerySearch mqs = MetadataQuerySearch.parseQuery("number>5");
        TopLevelItem tli1 = project;
        TopLevelItem tli2 = project2;
        List itemList = new ArrayList();
        itemList.add(tli1);
View Full Code Here

        FreeStyleProject project = createFreeStyleProject("open");
        FreeStyleProject project2 = createFreeStyleProject("secure");
        List<MetadataValue> list = new LinkedList<MetadataValue>();
        NumberMetadataValue number = new NumberMetadataValue("number", "description", NUMBR_VAL1, false);
        list.add(number);
        MetadataJobProperty property = project.getProperty(MetadataJobProperty.class);
        property.addChildren(list);
        list = new LinkedList<MetadataValue>();
        number = new NumberMetadataValue("number", "description", NUMBR_VAL2, false);
        list.add(number);
        MetadataJobProperty property2 = project2.getProperty(MetadataJobProperty.class);
        property2.addChildren(list);
        MetadataQuerySearch mqs = MetadataQuerySearch.parseQuery("number<=9");
        TopLevelItem tli1 = project;
        TopLevelItem tli2 = project2;
        List itemList = new ArrayList();
        itemList.add(tli1);
View Full Code Here

        FreeStyleProject project = createFreeStyleProject("open");
        FreeStyleProject project2 = createFreeStyleProject("secure");
        List<MetadataValue> list = new LinkedList<MetadataValue>();
        NumberMetadataValue number = new NumberMetadataValue("number", "description", NUMBR_VAL1, false);
        list.add(number);
        MetadataJobProperty property = project.getProperty(MetadataJobProperty.class);
        property.addChildren(list);
        list = new LinkedList<MetadataValue>();
        number = new NumberMetadataValue("number", "description", NUMBR_VAL2, false);
        list.add(number);
        MetadataJobProperty property2 = project2.getProperty(MetadataJobProperty.class);
        property2.addChildren(list);
        MetadataQuerySearch mqs = MetadataQuerySearch.parseQuery("number<9");
        TopLevelItem tli1 = project;
        TopLevelItem tli2 = project2;
        List itemList = new ArrayList();
        itemList.add(tli1);
View Full Code Here

                        }
                    } else {
                        throw new NoItemException("There is no build #" + build + " for job " + job);
                    }
                } else {
                    MetadataJobProperty property = (MetadataJobProperty)project.getProperty(MetadataJobProperty.class);
                    if (property != null) {
                        container = property;
                    } else if (createContainer) {
                        container = MetadataJobProperty.MetaDataJobPropertyDescriptor.instanceFor(project);
                    } else {
View Full Code Here

TOP

Related Classes of com.sonyericsson.hudson.plugins.metadata.model.MetadataJobProperty$MetaDataJobPropertyDescriptor

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.