W3C home > Mailing lists > Public > www-validator-cvs@w3.org > September 2009

2006/unicorn/src/org/w3c/unicorn/tasklisttree EnumCondType.java,1.3,1.4

From: Thomas Gambet via cvs-syncmail <cvsmail@w3.org>
Date: Mon, 21 Sep 2009 12:11:19 +0000
To: www-validator-cvs@w3.org
Message-Id: <E1Mphjj-00086l-13@lionel-hutz.w3.org>
Update of /sources/public/2006/unicorn/src/org/w3c/unicorn/tasklisttree
In directory hutz:/tmp/cvs-serv31153/src/org/w3c/unicorn/tasklisttree

Modified Files:
	EnumCondType.java 
Log Message:
added fromValue function

Index: EnumCondType.java
===================================================================
RCS file: /sources/public/2006/unicorn/src/org/w3c/unicorn/tasklisttree/EnumCondType.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- EnumCondType.java	16 Sep 2009 12:01:18 -0000	1.3
+++ EnumCondType.java	21 Sep 2009 12:11:16 -0000	1.4
@@ -13,5 +13,14 @@
 	public final String value() {
 		return this.sValue;
 	}
+	
+	public static EnumCondType fromValue(final String sValue) {
+		for (final EnumCondType aEnumCondType : EnumCondType.values()) {
+			if (aEnumCondType.sValue.equals(sValue)) {
+				return aEnumCondType;
+			}
+		}
+		return null;
+	}
 
 }
\ No newline at end of file
Received on Monday, 21 September 2009 12:11:28 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Thursday, 26 April 2012 12:55:14 GMT