pivot-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sandro Martini (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (PIVOT-799) extending Pivot collections
Date Fri, 20 Jul 2012 12:59:34 GMT

    [ https://issues.apache.org/jira/browse/PIVOT-799?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13419102#comment-13419102

Sandro Martini commented on PIVOT-799:

Other things that could be a good addition:
- add a maximum number of elements (by default -1 or no limit)
  -- use case: for example, put a limit in how many objects can be put in the resourceCache
(inside ApplicationContext)
- add some utility class (see in what package, inside core) to implement the concept of null-safe
data container (or monad, in Scala terms), and related concepts of Option, Some, None, etc
as found in Scala. Some reference:
  -- verify if could be good to start retrofit existing behavior to use them, but probably
not before release 3.0 ...

- add fallback methods like getOrElse in some Scala collections
- add method to apply to any collection element a transformation (or maybe a Command), like

Of course before all this I'll verify if/how we can do this (in Java), both as coding strategies
(if there are some pitfalls, etc), and by licensing (should not exist problems here, but I'll
do some check to be sure).

> extending Pivot collections
> ---------------------------
>                 Key: PIVOT-799
>                 URL: https://issues.apache.org/jira/browse/PIVOT-799
>             Project: Pivot
>          Issue Type: Improvement
>          Components: core-collections
>            Reporter: Sandro Martini
>            Assignee: Sandro Martini
>            Priority: Minor
>             Fix For: 2.1
> Add some usuful methods to Pivot Collections like those needed to process all elements,
going more "function style", like addAll, contains, etc ...
> To simplify usage from people coming from other languages, try to align to other languages
names/conventions (for what is possible) , like Scala, C# .
> Verify even if add a interface (defining a single method) that could be passed to some
methods to contain logic for processing all elements (like the apply() in Scala), and chose
a right name for it (maybe function or other similar).
> Some info here:
> http://apache-pivot-developers.417237.n3.nabble.com/Some-idea-on-extending-Pivot-collections-td3321472.html
> But for more changes in Collections (still to be discussed), wait the 3.0 ...

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message