<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>中文Flex例子 &#187; StringUtil</title>
	<atom:link href="http://blog.minidx.com/tag/stringutil/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.minidx.com</link>
	<description>中文Adobe Flex例子,Flex实例教程,RIA资源,全文检索技术,算法和数据结构</description>
	<lastBuildDate>Thu, 31 Mar 2011 03:22:33 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.5</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Flex中如何利用StyleManager.isColorName函数检查颜色名字是否合法的例子</title>
		<link>http://blog.minidx.com/2008/09/17/1401.html</link>
		<comments>http://blog.minidx.com/2008/09/17/1401.html#comments</comments>
		<pubDate>Tue, 16 Sep 2008 23:50:49 +0000</pubDate>
		<dc:creator>Minidxer</dc:creator>
				<category><![CDATA[Flex]]></category>
		<category><![CDATA[isColorName()]]></category>
		<category><![CDATA[registerColorName()]]></category>
		<category><![CDATA[StringUtil]]></category>
		<category><![CDATA[StyleManager]]></category>
		<category><![CDATA[trim]]></category>

		<guid isPermaLink="false">http://blog.minidx.com/?p=1401</guid>
		<description><![CDATA[接下来的例子演示了Flex中如何利用StyleManager.isColorName函数检查颜色名字是否合法。
让我们先来看一下Demo（可以右键View Source或点击这里察看源代码）：









下面是完整代码(或点击这里察看)：
Download: main.mxml&#60;?xml version=&#34;1.0&#34; encoding=&#34;utf-8&#34;?&#62;
&#60;!-- http://blog.flexexamples.com/2007/09/13/checking-whether-a-color-name-is-a-valid-color-in-flex-using-the-stylemanager-class/ --&#62;
&#60;mx:Application&#160;xmlns:mx=&#34;http://www.adobe.com/2006/mxml&#34;
&#160; &#160; &#160; &#160; layout=&#34;vertical&#34;
&#160; &#160; &#160; &#160; verticalAlign=&#34;middle&#34;
&#160; &#160; &#160; &#160; backgroundColor=&#34;white&#34;&#62;
&#160;
&#160; &#160; &#60;mx:Script&#62;
&#160; &#160; &#160; &#160; &#60;![CDATA[
&#160; &#160; &#160; &#160; &#160; &#160; import mx.styles.StyleManager;
&#160; &#160; &#160; &#160; &#160; &#160; import mx.utils.StringUtil;
&#160;
&#160; &#160; &#160; &#160; &#160; &#160; private function button_click(evt:MouseEvent):void {
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; [...]]]></description>
		<wfw:commentRss>http://blog.minidx.com/2008/09/17/1401.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Flex中利用StringUtil类的substitute()方法对字符串中的字符进行替换的例子</title>
		<link>http://blog.minidx.com/2008/08/24/1308.html</link>
		<comments>http://blog.minidx.com/2008/08/24/1308.html#comments</comments>
		<pubDate>Sun, 24 Aug 2008 06:56:13 +0000</pubDate>
		<dc:creator>Minidxer</dc:creator>
				<category><![CDATA[Flex]]></category>
		<category><![CDATA[StringUtil]]></category>
		<category><![CDATA[substitute]]></category>

		<guid isPermaLink="false">http://blog.minidx.com/2008/08/24/1308.html</guid>
		<description><![CDATA[很多系统中当用户注册或者作了某项操作的时候，系统会自动发送邮件或者消息给该用户，其中大部分的内容是一样的，不过比如用户名，用户的操作之类的则是不一样的。接下来的例子就演示了Flex中如何利用StringUtil类的substitute()方法，对字符串中的字符进行替换。
让我们先来看一下Demo（可以右键View Source或点击这里察看源代码）：









下面是完整代码(或点击这里察看)：
Download: main.mxml&#60;?xml version=&#34;1.0&#34; encoding=&#34;utf-8&#34;?&#62;
&#60;mx:Application&#160;xmlns:mx=&#34;http://www.adobe.com/2006/mxml&#34;
&#160; &#160; &#160; &#160; layout=&#34;vertical&#34;
&#160; &#160; &#160; &#160; verticalAlign=&#34;middle&#34;
&#160; &#160; &#160; &#160; backgroundColor=&#34;white&#34;&#62;
&#160;
&#160; &#160; &#60;mx:Script&#62;
&#160; &#160; &#160; &#160; &#60;![CDATA[
&#160; &#160; &#160; &#160; &#160; &#160; import mx.utils.StringUtil;
&#160;
&#160; &#160; &#160; &#160; &#160; &#160; private function button_click(evt:MouseEvent):void {
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; textArea.text = StringUtil.substitute(template,
&#160; &#160; &#160; &#160; &#160; &#160; &#160; [...]]]></description>
		<wfw:commentRss>http://blog.minidx.com/2008/08/24/1308.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Flex中利用StringUtil类的isWhitespace()方法检查字符是否空格的例子</title>
		<link>http://blog.minidx.com/2008/08/24/1307.html</link>
		<comments>http://blog.minidx.com/2008/08/24/1307.html#comments</comments>
		<pubDate>Sun, 24 Aug 2008 06:42:45 +0000</pubDate>
		<dc:creator>Minidxer</dc:creator>
				<category><![CDATA[Flex]]></category>
		<category><![CDATA[isWhitespace()]]></category>
		<category><![CDATA[RegExp]]></category>
		<category><![CDATA[Regular Expressions]]></category>
		<category><![CDATA[StringUtil]]></category>

		<guid isPermaLink="false">http://blog.minidx.com/2008/08/24/1307.html</guid>
		<description><![CDATA[前面的Flex中空格处理函数StringUtil类trim()方法用法的例子和Flex中利用StringUtil类的trimArrayElements函数进行空格处理的例子，说明的都是如何去除字符串中的空格，接下来的例子演示了Flex中如何利用StringUtil类的isWhitespace()方法，检查字符是否空格。
让我们先来看一下Demo（可以右键View Source或点击这里察看源代码）：









下面是完整代码(或点击这里察看)：
Download: main.mxml&#60;?xml version=&#34;1.0&#34; encoding=&#34;utf-8&#34;?&#62;
&#60;mx:Application&#160;xmlns:mx=&#34;http://www.adobe.com/2006/mxml&#34;
&#160; &#160; &#160; &#160; layout=&#34;vertical&#34;
&#160; &#160; &#160; &#160; verticalAlign=&#34;middle&#34;
&#160; &#160; &#160; &#160; backgroundColor=&#34;white&#34;&#62;
&#160;
&#160; &#160; &#60;mx:Script&#62;
&#160; &#160; &#160; &#160; &#60;![CDATA[
&#160; &#160; &#160; &#160; &#160; &#160; import mx.controls.dataGridClasses.DataGridColumn;
&#160; &#160; &#160; &#160; &#160; &#160; import mx.utils.StringUtil;
&#160;
&#160; &#160; &#160; &#160; &#160; &#160; private function isWhitespace_labelFunc(item:Object, column:DataGridColumn):String {
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; var [...]]]></description>
		<wfw:commentRss>http://blog.minidx.com/2008/08/24/1307.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Flex中利用StringUtil类的trimArrayElements函数进行空格处理的例子</title>
		<link>http://blog.minidx.com/2008/08/24/1306.html</link>
		<comments>http://blog.minidx.com/2008/08/24/1306.html#comments</comments>
		<pubDate>Sun, 24 Aug 2008 05:10:05 +0000</pubDate>
		<dc:creator>Minidxer</dc:creator>
				<category><![CDATA[Flex]]></category>
		<category><![CDATA[join()]]></category>
		<category><![CDATA[split]]></category>
		<category><![CDATA[StringUtil]]></category>
		<category><![CDATA[trimArrayElements()]]></category>

		<guid isPermaLink="false">http://blog.minidx.com/2008/08/24/1306.html</guid>
		<description><![CDATA[和前面Flex中空格处理函数StringUtil类trim()方法用法的例子类似的，接下来的例子演示了Flex中如何利用StringUtil类的trimArrayElements函数，进行空格处理。
让我们先来看一下Demo（可以右键View Source或点击这里察看源代码）：









下面是完整代码(或点击这里察看)：
Download: main.mxml&#60;?xml version=&#34;1.0&#34; encoding=&#34;utf-8&#34;?&#62;
&#60;mx:Application&#160;xmlns:mx=&#34;http://www.adobe.com/2006/mxml&#34;
&#160; &#160; &#160; &#160; layout=&#34;horizontal&#34;
&#160; &#160; &#160; &#160; verticalAlign=&#34;middle&#34;
&#160; &#160; &#160; &#160; backgroundColor=&#34;white&#34;
&#160; &#160; &#160; &#160; creationComplete=&#34;init()&#34;&#62;
&#160;
&#160; &#160; &#60;mx:Script&#62;
&#160; &#160; &#160; &#160; &#60;![CDATA[
&#160; &#160; &#160; &#160; &#160; &#160; import mx.utils.StringUtil;
&#160;
&#160; &#160; &#160; &#160; &#160; &#160; private function init():void {
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; var arrayStr:String = arrayToList(arr);
&#160; &#160; [...]]]></description>
		<wfw:commentRss>http://blog.minidx.com/2008/08/24/1306.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Flex中空格处理函数StringUtil类trim()方法用法的例子</title>
		<link>http://blog.minidx.com/2008/08/24/1305.html</link>
		<comments>http://blog.minidx.com/2008/08/24/1305.html#comments</comments>
		<pubDate>Sun, 24 Aug 2008 04:57:55 +0000</pubDate>
		<dc:creator>Minidxer</dc:creator>
				<category><![CDATA[Flex]]></category>
		<category><![CDATA[EmailValidator]]></category>
		<category><![CDATA[errorTip]]></category>
		<category><![CDATA[StringUtil]]></category>
		<category><![CDATA[StringValidator]]></category>
		<category><![CDATA[trim]]></category>
		<category><![CDATA[validateAll]]></category>
		<category><![CDATA[Validator]]></category>

		<guid isPermaLink="false">http://blog.minidx.com/2008/08/24/1305.html</guid>
		<description><![CDATA[接下来的例子演示了Flex中如何利用StringUtil类trim()方法对空格进行处理。
让我们先来看一下Demo（可以右键View Source或点击这里察看源代码）：









下面是完整代码(或点击这里察看)：
Download: main.mxml&#60;?xml version=&#34;1.0&#34; encoding=&#34;utf-8&#34;?&#62;
&#60;mx:Application&#160;xmlns:mx=&#34;http://www.adobe.com/2006/mxml&#34;
&#160; &#160; &#160; &#160; layout=&#34;vertical&#34;
&#160; &#160; &#160; &#160; verticalAlign=&#34;middle&#34;
&#160; &#160; &#160; &#160; backgroundColor=&#34;white&#34;&#62;
&#160;
&#160; &#160; &#60;mx:Style&#62;
&#160; &#160; &#160; &#160; .errorTip {
&#160; &#160; &#160; &#160; &#160; &#160; borderColor: haloBlue;
&#160; &#160; &#160; &#160; }
&#160; &#160; &#60;/mx:Style&#62;
&#160;
&#160; &#160; &#60;mx:Script&#62;
&#160; &#160; &#160; &#160; &#60;![CDATA[
&#160; &#160; &#160; &#160; &#160; &#160; import mx.controls.Alert;
&#160; &#160; &#160; &#160; &#160; &#160; [...]]]></description>
		<wfw:commentRss>http://blog.minidx.com/2008/08/24/1305.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk
Page Caching using disk (enhanced)
Database Caching 2/27 queries in 1.129 seconds using disk
Object Caching 423/822 objects using disk

Served from: blog.minidx.com @ 2012-02-09 20:30:51 -->
