io.shiftleft.codepropertygraph.generated.traversals.TraversalPropertyIsExternal.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of codepropertygraph-domain-classes_3 Show documentation
Show all versions of codepropertygraph-domain-classes_3 Show documentation
codepropertygraph-domain-classes
package io.shiftleft.codepropertygraph.generated.traversals
import io.shiftleft.codepropertygraph.generated.nodes
import io.shiftleft.codepropertygraph.generated.accessors.languagebootstrap.*
final class TraversalPropertyIsExternal[NodeType <: nodes.StoredNode & nodes.StaticType[nodes.HasIsExternalEMT]](
val traversal: Iterator[NodeType]
) extends AnyVal {
/** Traverse to isExternal property */
def isExternal: Iterator[Boolean] =
traversal.map(_.isExternal)
/** Traverse to nodes where the isExternal equals the given `value`
*/
def isExternal(value: Boolean): Iterator[NodeType] =
traversal.filter { _.isExternal == value }
}