Read Me First
What's XList ?
XList provides a wrapper object to treat AppleScript's list as iterator, stack and queue.
XList will fill many missing features of AppleScript's list.
Requirements
System
- OS X 10.9 or later
- Developed and tested on macOS 10.14.6
Depending Libraries
Required to install with XList .
How to Display Help
The manual consisted of the reference generated by AppleScriptDoc and sample code is stored in the bundle of "XList.scptd". After installation of OpenHelpBook.scptd, run "XList" from Script menu.
The detail manual of "XList" should be displayed in Help Viewer.
Install
Copy XList.scptd into either following locations.
Your Home/Library/Script Libraries/
or
/Library/Script Libraries/
History
- 1.8 -- 2020-06-17
- Removed dependency on XText.
- Removed as_xtext_with
- Use make_with_xlist of XText
- Added as_list
- each and each_rush return the target of XList instance.
- Changed “text item delimiters” in as_text_with, as_unicode_with and as_string_with is not restored.
- It is recommended to use make_with_xlist of XText.
- 1.7.3 -- 2020-04-10
- Improved performance of each, map, map_as_list.
- Added each_rush.
- 1.7.2 -- 2020-01-27
- Use OpenHelpBook.scptd instead of HelpBook.osax.
- 1.7.1 -- 2017-05-09
- Fixed links to XText in the help book.
- 1.7 -- 2016-10-18
- Enabled to work with AppleScript Libraries.
- Remove dependency on ModuleLoader.
- OS X 10.9 or later is required.
- 1.6r2 -- 2014-10-01
- Fixed : A script link of the sample code in the HelpBook does not work.
- 1.6 -- 2012-11-28
- "each", "map" and "map_as_list" will be passed contents of elements of a list to "do" handler of a script object intead of references to elements of a list.
- passing a referece to an element does not work with AppleScriptObjC.
- Added "enumerate".
- Added "set_item_at".
- 1.5 -- 2012-05-27
- Added "add_from_list".
- Added "shallow_copy".
- Added "deep_copy".
- Added "iterator".
- 1.4.1 -- 2012-04-21
- Update Help.
- Fixed : "Edit Link" and handler's copy link does not work in Mac OS X 10.6.
- item_at can accept list of indexes.
- Added as_text_with.
- 1.4 -- 2010-01-29
- Removed dependecy on "ShowHelpBook".
- Added "items_in_range"
- The "count" command is used to obtain length of a list instead of "length" property in "count_items".
- ModuleLoader 2.1 or later is required to load "XList".
- 1.3 -- 2008-03-20
- Removed dependency on StringEngine
- 1.2.1 -- 2008.02.02
- 1.2 -- 2008.01.05
- The handler 'next()' will raise error number 1351 when there is not next element in the list.
- In the previous version, 'missing value' is returned. But 'missing value' can be accepted as a list element.
- 1.1.1 -- 2007.12.04
- Fixed errors of the refernece manual.
- 1.1 -- 2007.07.10
- Renamed "SmartList" to "XList"
- Renamed "next_item" to "next"
- Added make_with , make, make_with_text, count_items, set_item, index_of, current_index, has_item,as_xtext_with, as_unicode_with, as_string_with
- 1.0.2 -- 2007.06.01
- Conetns of a list can be changed by map and each.
- A reference to an item of a list is passed to do handler.
- 1.0.1 -- 2007.05.30
- Added English document
- Added reset()
- Added all_items()
- Added each()
- 1.0 -- 2007.05.23