incubator-adffaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mat...@apache.org
Subject svn commit: r497726 - in /incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/javascript/META-INF/adf/jsLibs: CharSets.js CoreFormat.js
Date Fri, 19 Jan 2007 07:37:33 GMT
Author: matzew
Date: Thu Jan 18 23:37:32 2007
New Revision: 497726

URL: http://svn.apache.org/viewvc?view=rev&rev=497726
Log:
performance: don't send down to many hint messages; no need for standard converters and technical
validators like regExp or byteLength

Modified:
    incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/javascript/META-INF/adf/jsLibs/CharSets.js
    incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/javascript/META-INF/adf/jsLibs/CoreFormat.js

Modified: incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/javascript/META-INF/adf/jsLibs/CharSets.js
URL: http://svn.apache.org/viewvc/incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/javascript/META-INF/adf/jsLibs/CharSets.js?view=diff&rev=497726&r1=497725&r2=497726
==============================================================================
--- incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/javascript/META-INF/adf/jsLibs/CharSets.js
(original)
+++ incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/javascript/META-INF/adf/jsLibs/CharSets.js
Thu Jan 18 23:37:32 2007
@@ -47,22 +47,16 @@
   converter
   )
 {
-  var messages = new Array();
+  var messages = null;
   
   if(this._messages["hint"])
   {
+  	messages = new Array();
     messages.push(TrMessageFactory.createCustomMessage(
       this._messages["hint"],
 	    this._length)
 	  );
   }
-  else
-  {
-    messages.push(TrMessageFactory.createMessage(
-      "org.apache.myfaces.trinidad.validator.ByteLengthValidator.MAXIMUM_HINT",
-	    this._length)
-	  );
-  }
 	return messages;
 }
 CjkFormat.prototype.validate  = function(
@@ -125,22 +119,16 @@
   converter
   )
 {
-  var messages = new Array();
+  var messages = null;
   
   if(this._messages["hint"])
   {
+  	messages = new Array();
     messages.push(TrMessageFactory.createCustomMessage(
       this._messages["hint"],
 	    this._length)
 	  );
   }
-  else
-  {
-    messages.push(TrMessageFactory.createMessage(
-      "org.apache.myfaces.trinidad.validator.ByteLengthValidator.MAXIMUM_HINT",
-	    this._length)
-	  );
-  }
 	return messages;
 }
 Utf8Format.prototype.validate  = function(
@@ -209,19 +197,13 @@
   converter
   )
 {
-  var messages = new Array();
+  var messages = null;
   
   if(this._messages["hint"])
   {
+  	messages = new Array();
     messages.push(TrMessageFactory.createCustomMessage(
       this._messages["hint"],
-	    this._length)
-	  );
-  }
-  else
-  {
-    messages.push(TrMessageFactory.createMessage(
-      "org.apache.myfaces.trinidad.validator.ByteLengthValidator.MAXIMUM_HINT",
 	    this._length)
 	  );
   }

Modified: incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/javascript/META-INF/adf/jsLibs/CoreFormat.js
URL: http://svn.apache.org/viewvc/incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/javascript/META-INF/adf/jsLibs/CoreFormat.js?view=diff&rev=497726&r1=497725&r2=497726
==============================================================================
--- incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/javascript/META-INF/adf/jsLibs/CoreFormat.js
(original)
+++ incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/javascript/META-INF/adf/jsLibs/CoreFormat.js
Thu Jan 18 23:37:32 2007
@@ -37,9 +37,7 @@
 
 TrIntegerConverter.prototype.getFormatHint = function()
 {
-	return TrMessageFactory.createMessage(
-    "org.apache.myfaces.trinidad.convert.IntegerConverter.FORMAT_HINT",
-	  null);
+	return null;
 }
 
 TrIntegerConverter.prototype.getAsString = function(
@@ -85,9 +83,7 @@
 
 TrLongConverter.prototype.getFormatHint = function()
 {
-	return TrMessageFactory.createMessage(
-    "org.apache.myfaces.trinidad.convert.LongConverter.FORMAT_HINT",
-	  null);
+	return null;
 }
 
 TrLongConverter.prototype.getAsString = function(
@@ -133,9 +129,7 @@
 
 TrShortConverter.prototype.getFormatHint = function()
 {
-	return TrMessageFactory.createMessage(
-    "org.apache.myfaces.trinidad.convert.ShortConverter.FORMAT_HINT",
-	  null);
+	return null;
 }
 
 TrShortConverter.prototype.getAsString = function(
@@ -181,9 +175,7 @@
 
 TrByteConverter.prototype.getFormatHint = function()
 {
-	return TrMessageFactory.createMessage(
-    "org.apache.myfaces.trinidad.convert.ByteConverter.FORMAT_HINT",
-	  null);
+	return null;
 }
 
 TrByteConverter.prototype.getAsString = function(
@@ -230,9 +222,7 @@
 
 TrDoubleConverter.prototype.getFormatHint = function()
 {
-	return TrMessageFactory.createMessage(
-    "org.apache.myfaces.trinidad.convert.DoubleConverter.FORMAT_HINT",
-	  null);
+	return null;
 }
 
 TrDoubleConverter.prototype.getAsString = function(
@@ -278,9 +268,7 @@
 
 TrFloatConverter.prototype.getFormatHint = function()
 {
-	return TrMessageFactory.createMessage(
-    "org.apache.myfaces.trinidad.convert.FloatConverter.FORMAT_HINT",
-	  null);
+	return null;
 }
 
 TrFloatConverter.prototype.getAsString = function(
@@ -916,18 +904,12 @@
   converter
   )
 {
-  var hints = new Array();
+  var hints = null;
   if(this._messages["hint"])
   {
+  	hints = new Array();
     hints.push(TrMessageFactory.createCustomMessage(
       this._messages["hint"],
-	    ""+this._pattern)
-	  );
-  }
-  else
-  {
-    hints.push(TrMessageFactory.createMessage(
-      "org.apache.myfaces.trinidad.validator.RegExpValidator.NO_MATCH_HINT",
 	    ""+this._pattern)
 	  );
   }



Mime
View raw message