summaryrefslogtreecommitdiffstats
path: root/src/main/java/org/openslx/util/vm/VboxConfig.java
diff options
context:
space:
mode:
authorVictor Mocanu2017-11-20 15:16:54 +0100
committerVictor Mocanu2017-11-20 15:16:54 +0100
commit1967876ea2e8340a95d424ef873a4ab4e53e4a57 (patch)
treeadcb35fc3179e9863f196c8f5611d2753dee39a9 /src/main/java/org/openslx/util/vm/VboxConfig.java
parent[VBox] setter for the 3dacceleration works now, added new hardwareversion enu... (diff)
downloadmaster-sync-shared-1967876ea2e8340a95d424ef873a4ab4e53e4a57.tar.gz
master-sync-shared-1967876ea2e8340a95d424ef873a4ab4e53e4a57.tar.xz
master-sync-shared-1967876ea2e8340a95d424ef873a4ab4e53e4a57.zip
[VBox] improved and expanded the setters and getters for the enum types
removed debug messages
Diffstat (limited to 'src/main/java/org/openslx/util/vm/VboxConfig.java')
-rw-r--r--src/main/java/org/openslx/util/vm/VboxConfig.java26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/main/java/org/openslx/util/vm/VboxConfig.java b/src/main/java/org/openslx/util/vm/VboxConfig.java
index 6a44402..efab84b 100644
--- a/src/main/java/org/openslx/util/vm/VboxConfig.java
+++ b/src/main/java/org/openslx/util/vm/VboxConfig.java
@@ -281,6 +281,32 @@ public class VboxConfig
}
/**
+ * Function uses the findANode function to narrow down the wanted node using 2 attributes and
+ * their values
+ *
+ * @param targetTag
+ * @param targetAttr0
+ * @param value0
+ * @param targetAttr1
+ * @param value1
+ * @return
+ */
+ public Node findANode( String targetTag, String targetAttr0, String value0 )
+ {
+ Node returnNode = null;
+
+ NodeList foundNodes = findANode( targetTag );
+
+ for ( int i = 0; i < foundNodes.getLength(); i++ ) {
+ Element node = (Element)foundNodes.item( i );
+ if ( node.hasAttribute( targetAttr0 ) && node.getAttribute( targetAttr0 ).equals( value0 ) ) {
+ returnNode = foundNodes.item( i );
+ }
+ }
+ return returnNode;
+ }
+
+ /**
* Function used to change the value of an attribute
* Use this function if you know the targetNode is unique
*