Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用图形库,我需要从 relationship.subject 字段 ["idOrder"] 中对关系进行排序。有可能吗?如果 IdOrder 不是 int 而是日期?
是的,您可以为目前处于开发分支的 Swift 3 执行此操作。
_ = graph.search(forRelationship: ["T1"]).sorted { (a, b) -> Bool in return a.subject!["idOrder"] as! Int > b.subject!["idOrder"] as! Int }
一切顺利 :)