Search in sources :

Example 76 with FieldConfigCommonData

use of com.sldeditor.ui.detail.config.FieldConfigCommonData in project sldeditor by robward-scisys.

the class FieldConfigMarkerTest method testGetFillColourOpacity.

/**
 * Test method for
 * {@link com.sldeditor.ui.detail.config.symboltype.FieldConfigMarker#getFillColourOpacity()}.
 */
@Test
public void testGetFillColourOpacity() {
    boolean valueOnly = true;
    FieldConfigMarker field = new FieldConfigMarker(new FieldConfigCommonData(String.class, FieldIdEnum.NAME, "test label", valueOnly), null, null, null);
    assertNull(field.getFillColourOpacity());
}
Also used : FieldConfigMarker(com.sldeditor.ui.detail.config.symboltype.FieldConfigMarker) FieldConfigCommonData(com.sldeditor.ui.detail.config.FieldConfigCommonData) Test(org.junit.Test)

Example 77 with FieldConfigCommonData

use of com.sldeditor.ui.detail.config.FieldConfigCommonData in project sldeditor by robward-scisys.

the class FieldConfigFilenameTest method testSetUpdateSymbolListener.

/**
 * Test method for
 * {@link com.sldeditor.ui.detail.config.symboltype.externalgraphic.FieldConfigFilename#setUpdateSymbolListener(com.sldeditor.ui.iface.UpdateSymbolInterface)}.
 */
@Test
public void testSetUpdateSymbolListener() {
    boolean valueOnly = true;
    FieldConfigFilename field = new FieldConfigFilename(new FieldConfigCommonData(String.class, FieldIdEnum.NAME, "test label", valueOnly), null, null, null);
    field.setUpdateSymbolListener(null);
}
Also used : FieldConfigFilename(com.sldeditor.ui.detail.config.symboltype.externalgraphic.FieldConfigFilename) FieldConfigCommonData(com.sldeditor.ui.detail.config.FieldConfigCommonData) Test(org.junit.Test)

Example 78 with FieldConfigCommonData

use of com.sldeditor.ui.detail.config.FieldConfigCommonData in project sldeditor by robward-scisys.

the class FieldConfigFilenameTest method testGetFieldList.

/**
 * Test method for
 * {@link com.sldeditor.ui.detail.config.symboltype.externalgraphic.FieldConfigFilename#getFieldList(com.sldeditor.ui.detail.GraphicPanelFieldManager)}.
 */
@Test
public void testGetFieldList() {
    boolean valueOnly = true;
    FieldConfigFilename field = new FieldConfigFilename(new FieldConfigCommonData(String.class, FieldIdEnum.NAME, "test label", valueOnly), null, null, null);
    assertEquals(1, field.getFieldList(null).size());
}
Also used : FieldConfigFilename(com.sldeditor.ui.detail.config.symboltype.externalgraphic.FieldConfigFilename) FieldConfigCommonData(com.sldeditor.ui.detail.config.FieldConfigCommonData) Test(org.junit.Test)

Example 79 with FieldConfigCommonData

use of com.sldeditor.ui.detail.config.FieldConfigCommonData in project sldeditor by robward-scisys.

the class FieldConfigFilenameTest method testCreateCopy.

/**
 * Test method for
 * {@link com.sldeditor.ui.detail.config.symboltype.externalgraphic.FieldConfigFilename#createCopy(com.sldeditor.ui.detail.config.FieldConfigBase)}.
 */
@Test
public void testCreateCopy() {
    boolean valueOnly = true;
    class TestFieldConfigFilename extends FieldConfigFilename {

        public TestFieldConfigFilename(FieldConfigCommonData commonData) {
            super(commonData, null, null, null);
        }

        public FieldConfigPopulate callCreateCopy(FieldConfigBase fieldConfigBase) {
            return createCopy(fieldConfigBase);
        }
    }
    TestFieldConfigFilename field = new TestFieldConfigFilename(new FieldConfigCommonData(String.class, FieldIdEnum.NAME, "test label", valueOnly));
    FieldConfigFilename copy = (FieldConfigFilename) field.callCreateCopy(null);
    assertNull(copy);
    copy = (FieldConfigFilename) field.callCreateCopy(field);
    assertEquals(field.getFieldId(), copy.getFieldId());
    assertTrue(field.getLabel().compareTo(copy.getLabel()) == 0);
    assertEquals(field.isValueOnly(), copy.isValueOnly());
}
Also used : FieldConfigBase(com.sldeditor.ui.detail.config.FieldConfigBase) FieldConfigFilename(com.sldeditor.ui.detail.config.symboltype.externalgraphic.FieldConfigFilename) FieldConfigCommonData(com.sldeditor.ui.detail.config.FieldConfigCommonData) Test(org.junit.Test)

Example 80 with FieldConfigCommonData

use of com.sldeditor.ui.detail.config.FieldConfigCommonData in project sldeditor by robward-scisys.

the class FieldConfigFilenameTest method testJustSelected.

/**
 * Test method for
 * {@link com.sldeditor.ui.detail.config.symboltype.externalgraphic.FieldConfigFilename#justSelected()}.
 */
@Test
public void testJustSelected() {
    boolean valueOnly = true;
    FieldConfigFilename field = new FieldConfigFilename(new FieldConfigCommonData(String.class, FieldIdEnum.NAME, "test label", valueOnly), null, null, null);
    field.justSelected();
}
Also used : FieldConfigFilename(com.sldeditor.ui.detail.config.symboltype.externalgraphic.FieldConfigFilename) FieldConfigCommonData(com.sldeditor.ui.detail.config.FieldConfigCommonData) Test(org.junit.Test)

Aggregations

FieldConfigCommonData (com.sldeditor.ui.detail.config.FieldConfigCommonData)322 Test (org.junit.Test)316 Geometry (com.vividsolutions.jts.geom.Geometry)69 FieldIdEnum (com.sldeditor.common.xml.ui.FieldIdEnum)54 FieldConfigBase (com.sldeditor.ui.detail.config.FieldConfigBase)44 FieldConfigString (com.sldeditor.ui.detail.config.FieldConfigString)38 GraphicPanelFieldManager (com.sldeditor.ui.detail.GraphicPanelFieldManager)34 FieldConfigColour (com.sldeditor.ui.detail.config.FieldConfigColour)24 StyleBuilder (org.geotools.styling.StyleBuilder)24 FieldConfigMarker (com.sldeditor.ui.detail.config.symboltype.FieldConfigMarker)22 UndoEvent (com.sldeditor.common.undo.UndoEvent)20 FieldConfigSlider (com.sldeditor.ui.detail.config.FieldConfigSlider)20 FieldConfigSymbolType (com.sldeditor.ui.detail.config.FieldConfigSymbolType)20 Expression (org.opengis.filter.expression.Expression)20 FieldConfigWindBarbs (com.sldeditor.ui.detail.vendor.geoserver.marker.windbarb.FieldConfigWindBarbs)18 PointFillDetails (com.sldeditor.ui.detail.PointFillDetails)17 FieldConfigTTF (com.sldeditor.ui.detail.config.symboltype.ttf.FieldConfigTTF)17 FieldConfigFilename (com.sldeditor.ui.detail.config.symboltype.externalgraphic.FieldConfigFilename)16 FieldConfigArrow (com.sldeditor.ui.detail.vendor.geoserver.marker.arrow.FieldConfigArrow)16 FieldConfigWKT (com.sldeditor.ui.detail.vendor.geoserver.marker.wkt.FieldConfigWKT)16