|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.xmloperator.lambda2.net.impl.LambdaNetImpl
LambdaNet implementation.
| Constructor Summary | |
LambdaNetImpl()
Constructor of a LambdaNet that represents a free variable. |
|
LambdaNetImpl(PortImpl bodySupport)
Constructor of a cloned LambdaNet. |
|
| Method Summary | |
boolean |
booleanValue(int[] interactionStat)
Returns the boolean value of the Term (K or F) represented by this LambdaNet. |
void |
buildAbstraction()
Transforms this LambdaNet in such a way that its represented lambda term "t" is replaced by the abstraction "\x.t", where "x" doesn't occur within t. |
void |
buildAbstraction(Port freeVariableSupport)
Transforms this LambdaNet in such a way that its represented lambda term "t" is replaced by the abstraction "\x.t", where "x" is bound to the given variable of "t". |
void |
buildAbstraction(Port[] freeVariableSupports)
Transforms this LambdaNet in such a way that its represented lambda term "t" is replaced by the abstraction "\x.t", where "x" is bound to the given variables of "t". |
void |
buildApplication(LambdaNet argument)
Transforms this LambdaNet in such a way that its represented lambda term "t" is replaced by the application "tu" where "u" is the lambda term represented by the given LambdaNet. |
void |
buildApplication(LambdaNet argument,
int functionExponent)
Transforms this LambdaNet in such a way that its represented lambda term "t" is replaced by the application "(t^n)u" where "u" is the lambda term represented by the given LambdaNet and "n" an exponent. |
int |
cellCount()
Returns the count of cells of this LambdaNet. |
Port |
getBodySupport()
Returns the free Port that supports the interaction-net body. |
int |
getFreeVariableCount()
Returns the count of free variables. |
static void |
main(java.lang.String[] args)
|
long |
numeralValue(int[] interactionStat)
Returns the value modulo 2^63 of the Church numeral Term represented by this LambdaNet. |
void |
printNet(java.io.PrintStream out)
Print a graph representation of this LambdaNet. |
void |
printStat(java.io.PrintStream out)
Print a statistic of symbols of this LambdaNet. |
Term |
readBack(boolean inNormalForm,
int maxStepCount,
int[] interactionStat)
Read back the Term represented by this LambdaNet. |
int |
reduceUntilInterfaceNormalForm(int maxStepCount,
int[] interactionStat)
Reduces this LambdaNet until the interface has a normal form. |
static boolean |
test(java.io.PrintStream out,
boolean isVerbose)
Try some LambdaNets. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public LambdaNetImpl()
public LambdaNetImpl(PortImpl bodySupport)
bodySupport - a source LambdaNet body support.| Method Detail |
public void printNet(java.io.PrintStream out)
out - a PrintStream.public void printStat(java.io.PrintStream out)
out - a PrintStream.public int cellCount()
public static void main(java.lang.String[] args)
public static boolean test(java.io.PrintStream out,
boolean isVerbose)
out - the PrintStream to print results.isVerbose - if true then all tests have to be displayed.
public Port getBodySupport()
LambdaNet
getBodySupport in interface LambdaNetpublic int getFreeVariableCount()
LambdaNet
getFreeVariableCount in interface LambdaNetpublic void buildAbstraction()
LambdaNet
buildAbstraction in interface LambdaNetpublic void buildAbstraction(Port freeVariableSupport)
LambdaNet
buildAbstraction in interface LambdaNetfreeVariableSupport - a support of free variable.public void buildAbstraction(Port[] freeVariableSupports)
LambdaNet
buildAbstraction in interface LambdaNetfreeVariableSupports - a set of 0 or more support of free variable.public void buildApplication(LambdaNet argument)
LambdaNetTransforms this LambdaNet in such a way that its represented lambda term "t" is replaced by the application "tu" where "u" is the lambda term represented by the given LambdaNet.
The argument LambdaNet is consumed by the operation and is no more usable.
buildApplication in interface LambdaNetargument - an argument LambdaNet.
public void buildApplication(LambdaNet argument,
int functionExponent)
LambdaNetTransforms this LambdaNet in such a way that its represented lambda term "t" is replaced by the application "(t^n)u" where "u" is the lambda term represented by the given LambdaNet and "n" an exponent.
The argument LambdaNet is consumed by the operation and is no more usable.
buildApplication in interface LambdaNetargument - an argument LambdaNet.functionExponent - a function exponent
public int reduceUntilInterfaceNormalForm(int maxStepCount,
int[] interactionStat)
throws TooMuchReductionStepException
LambdaNetPost-condition: the body port is a principal Port or a free Port.
reduceUntilInterfaceNormalForm in interface LambdaNetmaxStepCount - a maximun step count. A negative value means no limit.interactionStat - an array of interaction type count. May be null.
TooMuchReductionStepException - if the given maximum count of step is not sufficient to
obtain an interface normal form.
public Term readBack(boolean inNormalForm,
int maxStepCount,
int[] interactionStat)
throws TooMuchReductionStepException
LambdaNetPre-condition: this LambdaNet must have no free variable.
readBack in interface LambdaNetinNormalForm - if true then returns a Term in normal form.maxStepCount - a maximum step count. A negative value means no limit.interactionStat - an array of interaction type count. May be null.
TooMuchReductionStepException - if the given maximum count of step is not sufficient to
obtain a normal form or an interface normal form.public boolean booleanValue(int[] interactionStat)
LambdaNet
booleanValue in interface LambdaNetinteractionStat - an array of interaction type count. May be null.
public long numeralValue(int[] interactionStat)
LambdaNet
numeralValue in interface LambdaNetinteractionStat - an array of interaction type count. May be null.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||