Java List Interface Java Actions

Content Type: Module
Categories: Utility

Overview

This module provides wrappers for the functions available in the List interface excluding those with an existing equivalent in OOB Mendix and those that return Java Iterators.

Documentation


Description

This module wraps the Java List interface functions that are not available in the OOB Mendix list methods excluding those that return iterators. https://docs.oracle.com/javase/8/docs/api/java/util/List.html


Typical usage scenario

Use this module to access or change a list at a specific index which is possible but is rather complicated in default Mendix.


Features and limitations

Wraps the following List Methods:

E remove(int index)

Removes the element at the specified position in this list (optional operation).

E set(int index, E element)

Replaces the element at the specified position in this list with the specified element (optional operation).

E get(int index)

Returns the element at the specified position in this list.

List subList(int fromIndex, int toIndex)

Returns a view of the portion of this list between the specified fromIndex, inclusive, and toIndex, exclusive.

int hashCode()

Returns the hash code value for this list.

void add(int index, E element)

Inserts the specified element at the specified position in this list (optional operation).

boolean addAll(int index, Collection c)

Inserts all of the elements in the specified collection into this list at the specified position (optional operation).

int indexOf(Object o)

Returns the index of the first occurrence of the specified element in this list, or -1 if this list does not contain the element.

int lastIndexOf(Object o)

Returns the index of the last occurrence of the specified element in this list, or -1 if this list does not contain the element.


Dependencies

Mendix 10.4 or above required to install.


Installation

Download from the Mendix Marketplace.


You can contact me at samuel.egan@mendix.com if you have questions.

Releases

Version: 1.0.0
Framework Version: 10.4.0
Release Notes: Java List Interface Java Actions Module 1.0.0 This module integrates Java's List interface methods into Mendix, enabling developers to manage list data with Java functions not available OOB. Features: Element Removal by Index: remove(int index) method implementation. Element Replacement: set(int index, E element) method integration. Element Retrieval: get(int index) function available. SubList Creation: subList(int fromIndex, int toIndex) method wrapped. Hash Code Calculation: hashCode() method for list objects included. Element Insertion: add(int index, E element) functionality added. Bulk Insertion: addAll(int index, Collection c) for inserting collections at an index. First Occurrence Index: indexOf(Object o) method to find an element's index. Last Occurrence Index: lastIndexOf(Object o) method for indexing last occurrences. Prerequisites Mendix version 10.4 or above. Installation Import the module into your Mendix project from the Mendix Marketplace. Usage Access the Java List functionalities through the Java actions in the module, callable from microflows. Questions Contact samuel.egan@mendix.com