ÿÌìѧһµãflash£¨63£© ¶ÁÈ¡xmlºóµÄ¼òµ¥·ÖÒ³´¦Àí
Õâ¸ö¶«Î÷¹¦Äܼܺòµ¥£¬Ã»ÓÐʲô¼¼Êõº¬Á¿¡£Ö»ÊǼǼһÏ¡£
xml µÄÊý¾Ý»ñÈ¡ºó£¬¿ÉÒÔͨ¹ýÒ»¸ö¼òµ¥·ÖÒ³´¦ÀíÀ´Íê³É¼òµ¥·ÖҳЧ¹û¡£
1.ÀûÓÃÇóÓàºÍ³ý·¨µÄ·½·¨ÅжÏÒ³Êý
Õâ¸öÊÇÒ»¸ö±È½Ï³£¼ûµÄ×ö·¨£¬Ò²ÊÇÒ»ÖÖ°ì·¨¡£ÔÚÕâÀ²»¶ÔÕâÖÖ·ÖÒ³´¦ÀíÒª´ïµ½Ê²Ã´×îÓÅ»¯µÄЧ¹û½øÐÐÌÖÂÛ£¬ÕâÀïÖ»ÊÇ̽ÌÖÒ»ÖÖ°ì·¨¡£¶ÔһЩÊý¾ÝÁ¿²»´óµÄ×ö·¨£¬¿ÉÒÔ³¢ÊÔÒ»ÏÂÕâЩ¡£È»¶ø¶ÔÓÚ¹ý´óµÄÊý¾ÝÁ¿£¬ÔòÐèÒªÆäËû°ì·¨´¦Àí¡£ÎÒ¶ÔÊý¾Ý¿â²¢²»ÊìϤ£¬ÉõÖÁ¿ÉÒÔ˵ÔçÒѾÒÅÍüÁ˺ܶࡣ²»¹ý£¬ÀûÓÃÏÖÔÚµÄ×ÊÔ´´¦ÀíÒ»ÏÂÕâЩ»¹Ëã¿ÉÒÔ¡£
¼ÙÉ裬xml ÓÐ50ÌõµÄÐÅÏ¢£¬ÎÒÃÇÿһҳֻÊÇÏÔʾ10Ìõ£¬Ôò50/10=5;¼ÆËã³ö5Ò³¡£
¼ÙÉ裬xml ÓÐ51ÌõÐÅÏ¢£¬ÎÒÃÇÐèÒª½øÐзÖÒ³£¬Ã¿Ò»Ò³ÏÔʾ10Ìõ£¬Ôò51/10=5.....1(Óà1) ÔòÎÒÃÇÐèÒª·ÖÒ³ÊýΪ5+1=6Ò³¡£
¿ÉÒÔ¼ÙÉèÍÆµ¼£¬µ±³ý¾¡µÄʱºò£¬ÈÝÒ×¼ÆËã³öÒ³Êý£¬µ±²»ÄܼÆËã³ö£¬ÎÒÃÇÔòͨ¹ýÇóÓàµÄ·½Ê½À´ÅжÏÊÇ·ñÇó¿ÉÒÔÕû³ý¡£ (Ò³Êý%2==0).
ÏÂÃæ¾ÍÊÇÒ»¸ö˼·¡£
if(×ÜÒ³Êý%2==0)
{
·ÖÒ³Êý=×ÜÒ³Êý/ÿһҳµÄÌõÊý
}
else
{
·ÖÒ³Êý=×ÜÒ³Êý/ÿһҳµÄÌõÊý+1£»
}
ÓÐÁËÕâ¸ö°ì·¨Ö®ºó£¬ÎÒÃÇдһ¸ö¼òµ¥ÀàʵÏÖÕâ¸ö¹¦ÄÜ¡£
package com.web
{
//·ÖÒ³Àà
public class Page
{
private var max:int;
private var pagenum:int;
private var currentPages:int;
public function Page()
{
}
//ÉèÖ÷ÖÒ³ÏîÊý
public function set MaxRow(max:int):void
{
this.max=max;
}
//»ñÈ¡·ÖÒ³ÏîÊý
public function get MaxRow():int
{
return max;
}
public function set currentPage(value:int):void
{
this.currentPages=value;
}
public function get currentPage():int
{
return currentPages;
}
//»ñÈ¡×ܵķÖÒ³Êý£¬ÀûÓÃÇóÓàµÄ·½Ê½ÅжÏÊDz»ÊÇÕûÒ³
public function getPageNumber(total:int):int
{
if (total%MaxRow==0)
{
pagenum=total/MaxRow;
} else
{
pagenum=int(total/MaxRow)+1;
}
return pagenum;
}
public function get TotalPage():int
{
return pagenum;
}
//ÏÔʾҳÂë
public function getPage():Str
Ïà¹ØÎĵµ£º
2440+NAND Flash£¨K9F1208UOM£©×ܽá ÊÕ²Ø
2440+NAND Flash£¨K9F1208UOM£©×ܽ᣺
1. ÒÔPageΪµ¥Î»¶Áд£¬´ËFlashΪSmall Page Flash£¬¼´Ã¿Ò³Îª528Byte£¨512 Byte +16 Byte£©
2. ÒÔBlockΪµ¥Î»²Á³ý£¬Ã¿¸öBlockΪ£¨16K+512£©Byte¼´Îª32 Page
3. Õû¸öFlash·ÖΪMain area£¨Êý¾Ý´æ´¢£©ºÍSpare ar ......
1. Ò»°ãÇé¿öÏÂʹÓÃÒÔÏ´úÂë¼´¿É½«XML×Ö·û´®ÖØÐ¸ñʽ»¯£º
private string FormatXml(string source)
{
StringBuilder ......
ÔÚ¹¤×÷Öо³£Óöµ½µ½ÁíÍâÒ»¸ö·þÎñÆ÷¶ÁÈ¡Êý¾Ý£¬ÆäÖÐÒ»ÖÖ×î³£Óõķ½·¨£¬¾ÍÊÇÓÃxml½øÐÐÊý¾Ý´«µÝ£¬±ÈÈçA·þÎñÆ÷µ½B·þÎñÆ÷µÃµ½¶ÔÓ¦µÄxml¸ñʽµÄÊý¾Ý£¬AµÃµ½Ö®ºó½øÐнâÎö¡£Ò»°ãÕâÖÖ½âÎö·ÖΪDOM½âÎöºÍSAX½âÎö¡£ÕâÀï²»ÊÇ̽ÌÖDOMÓëSAX½âÎöµÄÇø±ðºÍÓŵ㣬ֻÊǽéÉÜÒ»¸öС¿ò¼Ü£¬ÊµÏÖJAVABeanºÍXMLµÄת»»£¬Éµ¹ÏʽµÄת»»¡£----- ......
ÕâÊÇÒ»¸öÓÃJAVA W3C DOM ½øÐÐXML²Ù×÷µÄÀý×Ó£¬°üº¬Á˲éѯ¡¢Ôö¼Ó¡¢Ð޸ġ¢É¾³ý¡¢±£´æµÄ»ù±¾²Ù×÷¡£½ÏÍêÕûµÄÃèÊöÁËÒ»¸öXMLµÄÕû¸ö²Ù×÷Á÷³Ì¡£ÊʺϸÕÈëÃÅJAVA XML²Ù×÷µÄÅóÓѲο¼ºÍѧϰ¡£
¼ÙÉèÓÐXMLÎļþ£ºtest1.xml
<?xml version="1.0" encoding="GBK"?>
<books>
<book>
<name>¹þÀï²¨ÌØ</name>
......
ËäÈ»ÎÒ¶Ô³´¹ÉÐËȤ²»´ó£¬µ«ÊÇÎÒ¶ÔÀïÃæµÄÊý¾ÝºÍÓ¦Ó÷´¶øÓеãÐËȤ¡£Õâ¸öflash ÊÇ×î½üÎÞÒâÖп´µ½µÄ¡£Õâ¸öflash °æ±¾µÄ¹¦ÄÜ±È½ÏÆëÈ«¡£Ò²ÊÇÒ»¸öÄѵõÄÓ¦Óá£
flash ÔÚÓ¦Óõ½½ðÈÚµÄÊý¾Ý·ÖÎöÉÏ£¬ÌرðµÄÊÇͼÐεķ½ÃæÓÐÒ»¶¨µÄÓÅÊÆËùÔÚ¡£Ôø¾¸ú±ðÈËÁĹýһϣ¬¿ª·¢½ðÈÚÉçÇøºÜ¶à³Ì¶ÈÉÏ»á¸úÕâЩÊý¾Ý»ñÈ¡ºÍÏÔʾ´ò½»µÀ¡£Ò²¾ÍÊÇ˵ ¶ ......