This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class EvalTree<T> implements AbstractEvalTree<T> { | |
/** | |
* All nodes in the evaluation tree. Root node is the first element of the array with 0th index. | |
*\ | |
*/ | |
AbstractEvalNode[] _nodes; | |
/** | |
* Length of list of children of a node in {@link #_nodes}. | |
* <code>_childCounts[i]</code> corresponds to number of children of <code>_nodes[i]</code> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"operations" :[{ | |
"grammarId" : "interface-locale", | |
"description" : "Implementation of <code>interface-locale</code> operation of Lix DSL", | |
"externalDoc" : "The interface-locale field is a UI setting chosen by each member which controls which language the LinkedIn user interface renders in. Members can change it any time. NOTE: There is another selector, locale, which is the property set at the time of registration and user can never change it. See go/lixfaq more details.", | |
"category" : "member-profile", | |
"predefinedValueResourceName" : "locales", | |
"predefinedImplementation" : { | |
"com.linkedin.lix.dsl.v2.grammar.data.UserAndEntityContextsReadOperationData" : { | |
"userCtxPropertyName" : "interface-locale", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class EvalNode<RETURN_TYPE> { | |
List<EvalNode> children = new ArrayList<>(); | |
RETURN_TYPE compute(DslExecutionContext context, AbstractEvalTree tree, int thisNodePosition); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public interface AbstractEvalNode<RETURN_TYPE> { | |
RETURN_TYPE compute(DslExecutionContext context, AbstractEvalTree tree, int thisNodePosition); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public interface AbstractEvalTree { | |
int size(); | |
Object computeNode(int nodePosition, DslExecutionContext context); | |
AbstractEvalNode getRoot(); | |
AbstractEvalNode getNode(int nodePosition); | |
IntList getChildPositions(int parentNodePosition); | |
int getChildListOffset(int nodeId); | |
int getChildCount(int nodePosition); |