kiama.attribution.UncachedAttribution

class UncachedAttribute

[source: kiama/attribution/UncachedAttribution.scala]

class UncachedAttribute[T <: AnyRef, U](f : scala.PartialFunction[T, U])
extends scala.PartialFunction[T, U]
An attribute of a node type T with value of type U, supported by a circularity test. The value of the attribute is computed by the function f. f will be called each time the value of the attribute is accessed. f should not itself require the value of this attribute. If it does, a circularity error is reported.
Method Summary
def apply (t : T) : U
Return the value of this attribute for node t, raising an error if it depends on itself.
def isDefinedAt (t : T) : Boolean
An uncached attribute is defined at the same places as its defining function.
Methods inherited from scala.PartialFunction
scala.PartialFunction.orElse, scala.PartialFunction.andThen
Methods inherited from scala.Function1
scala.Function1.toString, scala.Function1.compose
Methods inherited from AnyRef
getClass, hashCode, equals, clone, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized
Methods inherited from Any
==, !=, isInstanceOf, asInstanceOf
Method Details
def apply(t : T) : U
Return the value of this attribute for node t, raising an error if it depends on itself.

def isDefinedAt(t : T) : Boolean
An uncached attribute is defined at the same places as its defining function.
Overrides
scala.PartialFunction.scala.PartialFunction.isDefinedAt