-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Built-in join function #118
Conversation
…ist + added tests
Description | ||
----------- | ||
This function takes a delimeter and a list of strings, or each of the strings | ||
individually, and joins them with the given delimeter. Only strings can be |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
or list of strings
. you probably mean Only (list of) strings can be ...
import org.quattor.pan.dml.functions.Debug; | ||
import org.quattor.pan.dml.functions.DebugSuppressed; | ||
import org.quattor.pan.dml.functions.Delete; | ||
import org.quattor.pan.dml.functions.*; | ||
import org.quattor.pan.dml.functions.Deprecated; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do you keep the Deprecated
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Otherwise Java doesn't know whether it should use org.quattor.pan.dml.functions.Deprecated or java.lang.Deprecated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is one of the main reasons wildcard imports in Java are debated so much.
retest this please |
retest this please |
3 similar comments
retest this please |
retest this please |
retest this please |
int length = ops.length; | ||
|
||
for (int i = 1; i < length; i++) { | ||
Element e = ops[i].execute(context); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does this do? It looks recursive.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not recursive, it just loops over the arguments and executes them. The execution is needed to get the actual value when for example passing variables to the function.
Also fixes #120