部分代码

var arrayOfCat:ArrayCollection=outerDocument.getCagegory();   // 需要排序的数组

//创建SortField对象
var sortField:SortField = new SortField();    
sortField.name = "SortNumber";      // 这里是ArraryCollection的一个对象的属性 相当于 arrayOfCat[0] as Object 有一个属性 SortNumber
sortField.numeric = true;        

//创建Sort对象
var sortObj:Sort = new Sort();
sortObj.fields = [sortField];

//Sort对象h和数组关联
arrayOfCat.sort = sortObj;
arrayOfCat.refresh();

Flex 排序 SortField and Sort的更多相关文章

  1. 排序合并连接(sort merge join)的原理

    排序合并连接(sort merge join)的原理 排序合并连接(sort merge join)的原理     排序合并连接(sort merge join)       访问次数:两张表都只会访 ...

  2. [大牛翻译系列]Hadoop(5)MapReduce 排序:次排序(Secondary sort)

    4.2 排序(SORT) 在MapReduce中,排序的目的有两个: MapReduce可以通过排序将Map输出的键分组.然后每组键调用一次reduce. 在某些需要排序的特定场景中,用户可以将作业( ...

  3. 《算法4》2.1 - 选择排序算法(Selection Sort), Python实现

    选择排序算法(Selection Sort)是排序算法的一种初级算法.虽然比较简单,但是基础,理解了有助于后面学习更高深算法,勿以勿小而不为. 排序算法的语言描述: 给定一组物体,根据他们的某种可量化 ...

  4. 编写一个类,其中包含一个排序的方法Sort(),当传入的是一串整数,就按照从小到大的顺序输出,如果传入的是一个字符串,就将字符串反序输出。

    namespace test2 { class Program { /// <summary> /// 编写一个类,其中包含一个排序的方法Sort(),当传入的是一串整数,就按照从小到大的 ...

  5. 简单选择排序 Selection Sort 和树形选择排序 Tree Selection Sort

    选择排序 Selection Sort 选择排序的基本思想是:每一趟在剩余未排序的若干记录中选取关键字最小的(也可以是最大的,本文中均考虑排升序)记录作为有序序列中下一个记录. 如第i趟选择排序就是在 ...

  6. 6种字符串数组的java排序 (String array sort)

    注意,本文不是字符串排序,是字符串数组的排序. 方法分别是: 1.低位优先键索引排序 2.高位优先建索引排序 3.Java自带排序(经过调优的归并排序) 4.冒泡排序 5.快速排序 6.三向快速排序 ...

  7. Python排序算法——希尔排序(Shell’s Sort)

    有趣的事,Python永远不会缺席! 如需转发,请注明出处:小婷儿的python https://www.cnblogs.com/xxtalhr/p/10793487.html 一.希尔排序(Shel ...

  8. 简单选择排序(Simple Selection Sort)

    body, table{font-family: 微软雅黑; font-size: 13.5pt} table{border-collapse: collapse; border: solid gra ...

  9. 拓扑排序(Topological Sort)

    Graph 拓扑排序(Topological Sort) 假设一个应用场景:你用 C 编写了一个爬虫工具,其中有很多自定义的库:queue.c.queue.h.stack.c.stack.h.heap ...

随机推荐

  1. JMeter学习(十七)JMeter测试MongoDB(转载)

    转载自 http://www.cnblogs.com/yangxia-test JMeter测试MongoDB性能有两种方式,一种是利用JMeter直接进行测试MongoDB,还有一种是写Java代码 ...

  2. jdbctemplate 批量插入

    public void batchImport(List<Map<String, Object>> list) { String sql = "insert into ...

  3. 修改nginx日志格式为json

    Nginx 日志默认为普通文本的格式 /Oct/::: +] "https://boss.zbt.com/finance/partner/create-account-gateway?id= ...

  4. rancher2 HA部署注意事项

    参考: https://rancher.com/docs/rancher/v2.x/en/installation/ha-server-install/ https://www.cnblogs.com ...

  5. Balanced Numbers (数位DP)

    Balanced Numbers https://vjudge.net/contest/287810#problem/K Balanced numbers have been used by math ...

  6. Qt的pro文件--项目配置的部分字段

    Qt项目配置的部分字段: 库: LIBS += -L /usr/local/lib -lpcap INCLUDEPATH += /usr/local/include/

  7. TZOJ 1210 The area(微积分)

    描述 Ignatius bought a land last week, but he didn't know the area of the land because the land is enc ...

  8. PTA 7-2 符号配对(栈模拟)

    请编写程序检查C语言源程序中下列符号是否配对:/*与*/.(与).[与].{与}. 输入格式: 输入为一个C语言源程序.当读到某一行中只有一个句点.和一个回车的时候,标志着输入结束.程序中需要检查配对 ...

  9. [leetcode]128. Longest Consecutive Sequence最长连续序列

    Given an unsorted array of integers, find the length of the longest consecutive elements sequence. Y ...

  10. 实现mapper接口注入的两种方式,以及后台的使用区别

    1.使用模板方式: <!--使用模板类实现mybatis --> <bean id="sqlSession" class="org.mybatis.sp ...