[Tech] Added info on EToolbox Lists in-code creation
@@ -60,9 +60,28 @@ Note: if you create your List Item anew, and do not have special requirements re
The Lists can be edited similarly to any other page. You can change the type of *Item Component* used in a list (even after the list has been populated with data) via the page properties.
+### Creating Lists in code
+[ListHelper](../../core/src/main/java/com/exadel/aem/toolkit/core/lists/utils/ListHelper.java) is a helper class that provides the ability to create a new EToolbox List from Java code. You can create a List out of a collection of *SimpleListItem*-s, or a collection of arbitrary Sling models, or a list of `Map` instances, or else a list of Sling *Resource*-s:
+```
+
+ResourceResolver currentResourceResolver = /*... */;
+String path = "/content/lists/myNewList";
+List<MyModel> models = Arrays.asList(new MyModel("First"), new MyModel("Second"));
+
+Page myNewList = ListHelper.createList(resourceResolver, path, models);
+
+// ...
+
+var propertyMaps = Arrays.asList(ImmutableMap.of("foo", "bar", "answer": 42), /* ... */);
+Page myAnotherList = ListHelper.createList(resourceResolver, path, propertyMaps);
+
+```
+You can find more examples in [ListHelperTest](../../core/src/test/java/com/exadel/aem/toolkit/core/lists/utils/ListHelperTest.java)
+
+
### Retrieving Lists' content programmatically
-[ListHelper](../../core/src/main/java/com/exadel/aem/toolkit/core/lists/utils/ListHelper.java) is a helper class that provides the ability to retrieve contents of any list by its path. See examples below:
+Apart from creating lists, [ListHelper](../../core/src/main/java/com/exadel/aem/toolkit/core/lists/utils/ListHelper.java) provides the ability to retrieve contents of any list by its path. See examples below:
```
List<ItemModel> models = ListHelper.getList(resolver, "/content/myList", ItemModel.class);
Map<String, String> mapping = ListHelper.getMap(resolver, "/content/myList");
