Examples of ODOMElementSelection


Examples of com.volantis.mcs.eclipse.common.odom.ODOMElementSelection

                        }
                        if (selectedDeviceIdentification != null) {
                            selectedDeviceIdentification.removeChangeListener(
                                    odomChangeListener);
                        }
                        ODOMElementSelection selection = event.getSelection();
                        if (selection.isEmpty()) {
                            // ensure the selectedDevice and
                            // selectedDeviceIndentification fields are set to
                            // null to reflect the fact that no device is selected
                            selectedDevice = null;
                            selectedDeviceIdentification = null;
                            listBuilder.setEnabled(false);
                        } else {
                            // update the selectedDevice and
                            // selectedDeviceIndentification fields
                            selectedDevice =
                                    (ODOMElement) selection.getFirstElement();
                            selectedDevice.addChangeListener(odomChangeListener);
                            selectedDeviceIdentification =
                                    (ODOMElement) context.
                                    getDeviceRepositoryAccessorManager().
                                    retrieveDeviceIdentification(
View Full Code Here

Examples of com.volantis.mcs.eclipse.common.odom.ODOMElementSelection

                final ODOMEditorContext context) {

            ODOMElementSelectionListener listener =
                    new ODOMElementSelectionListener() {
                        public void selectionChanged(ODOMElementSelectionEvent event) {
                            ODOMElementSelection selection =
                                    event.getSelection();

                            // Determine the current selection state for use in generating
                            // the context menu content
                            deviceLayoutSelection = DeviceLayoutSelection.NONE;

                            for (Iterator i = selection.iterator();
                                 i.hasNext();) {
                                final ODOMElement deviceLayout =
                                    (ODOMElement) i.next();

                                if (deviceLayout.getName().equals(
View Full Code Here

Examples of com.volantis.mcs.eclipse.common.odom.ODOMElementSelection

        deviceSelectionListener =
                new ODOMElementSelectionListener() {
                    public void selectionChanged(
                            ODOMElementSelectionEvent event) {
                        // retrieve the current selection
                        ODOMElementSelection selection = event.getSelection();
                        // store away the currently selected device
                        if (!selection.isEmpty()) {
                            selectedDevice =
                                    (ODOMElement) selection.getFirstElement();
                        } else {
                            selectedDevice = null;
                        }

                        updatePage();
View Full Code Here

Examples of com.volantis.mcs.eclipse.common.odom.ODOMElementSelection

        // element selections.
        context.getODOMSelectionManager().
                addSelectionListener(new ODOMElementSelectionListener() {

                    public void selectionChanged(ODOMElementSelectionEvent event) {
                        ODOMElementSelection selection = event.getSelection();

                        if (!selection.isEmpty()) {
                            Element deviceElement =
                                    (Element) selection.getFirstElement();
                            // Retrieve the device name.
                            final String deviceName =
                                    deviceElement.getAttributeValue(
                                            DeviceRepositorySchemaConstants.
                                    DEVICE_NAME_ATTRIBUTE);
View Full Code Here

Examples of com.volantis.mcs.eclipse.common.odom.ODOMElementSelection

                        }
                        if (selectedDeviceIdentification != null) {
                            selectedDeviceIdentification.removeChangeListener(
                                    odomChangeListener);
                        }
                        ODOMElementSelection selection = event.getSelection();
                        if (selection.isEmpty()) {
                            // ensure the selectedDevice and
                            // selectedDeviceIndentification fields are set to
                            // null to reflect the fact that no device is selected
                            selectedDevice = null;
                            selectedDeviceIdentification = null;
                            listValueBuilder.setEnabled(false);
                        } else {
                            // update the selectedDevice and
                            // selectedDeviceIndentification fields
                            selectedDevice =
                                    (ODOMElement) selection.getFirstElement();
                            selectedDevice.addChangeListener(odomChangeListener);
                            selectedDeviceIdentification =
                                    (ODOMElement) context.
                                    getDeviceRepositoryAccessorManager().
                                    retrieveDeviceIdentification(
View Full Code Here

Examples of com.volantis.mcs.eclipse.common.odom.ODOMElementSelection

        DeviceRepositoryAccessorManager dram =
                context.getDeviceRepositoryAccessorManager();
        Element device = dram.getHierarchyDeviceElement(deviceName);
        List selection = new ArrayList();
        selection.add(device);
        setSelection(new ODOMElementSelection(selection));
    }
View Full Code Here

Examples of com.volantis.mcs.eclipse.common.odom.ODOMElementSelection

                        }
                        if (selectedDeviceIdentification != null) {
                            selectedDeviceIdentification.removeChangeListener(
                                    odomChangeListener);
                        }
                        ODOMElementSelection selection = event.getSelection();
                        if (selection.isEmpty()) {
                            // ensure the selectedDevice and
                            // selectedDeviceIndentification fields are set to
                            // null to reflect the fact that no device is selected
                            selectedDevice = null;
                            selectedDeviceIdentification = null;
                            listBuilder.setEnabled(false);
                        } else {
                            // update the selectedDevice and
                            // selectedDeviceIndentification fields
                            selectedDevice =
                                    (ODOMElement) selection.getFirstElement();
                            selectedDevice.addChangeListener(odomChangeListener);
                            selectedDeviceIdentification =
                                    (ODOMElement) context.
                                    getDeviceRepositoryAccessorManager().
                                    retrieveDeviceTACElement(getSelectedDeviceName());
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.