Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.mindswap.pellet.rules
Class VariableBinding

    java.lang.Object
      org.mindswap.pellet.rules.VariableBinding

    public class VariableBinding

extends java.lang.Object

Title: Variable Binding

Description: Keeps variable bindings. Data and Individual variables are kept in seperate name spaces.

Copyright: Copyright (c) 2007

Company: Clark & Parsia, LLC.

Author:
  Ron Alford

Constructor Summary
`VariableBinding(ABox abox)`
`VariableBinding(VariableBinding binding)` Shallow copies the binding maps.

Method Summary
`boolean` | `containsKey(AtomDVariable key)`
`boolean` | `containsKey(AtomIVariable key)`
`java.util.Set<java.util.Map.Entry<? extends AtomVariable,? extends Node>>` | `entrySet()`
`boolean` | `equals(java.lang.Object other)`
`Literal` | `get(AtomDObject key)` If the key is a variable, return the node associated with it in the map.
`Individual` | `get(AtomIObject key)` If the key is a variable, return the individual associated with it in the map.
`int` | `hashCode()`
`Literal` | `set(AtomDObject key, Literal value)` If the key is a data variable, set the value.
`Literal` | `set(AtomDVariable key, aterm.ATermAppl value)`
`Individual` | `set(AtomIObject key, Individual value)` If the key is an instance variable, set the value.
`Individual` | `set(AtomIVariable key, aterm.ATermAppl value)`
`java.lang.String` | `toString()`

Methods inherited from class java.lang.Object
`getClass, notify, notifyAll, wait, wait, wait`

Constructor Detail

### VariableBinding

    public VariableBinding(ABox abox)

### VariableBinding

    public VariableBinding(VariableBinding binding)

  Shallow copies the binding maps.

Method Detail

### containsKey

    public boolean containsKey(AtomDVariable key)

### containsKey

    public boolean containsKey(AtomIVariable key)

### entrySet

    public java.util.Set<java.util.Map.Entry<? extends AtomVariable,? extends Node>> entrySet()

### equals

    public boolean equals(java.lang.Object other)

  Overrides:
    `equals` in class `java.lang.Object`

### get

    public Literal get(AtomDObject key)

  If the key is a variable, return the node associated with it in the map. If the key is a constant, return the corresponding node from the abox.

### get

    public Individual get(AtomIObject key)

  If the key is a variable, return the individual associated with it in the map. If the key is a constant, return the corresponding individual from the abox.

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `java.lang.Object`

### set

    public Literal set(AtomDObject key,
                       Literal value)

  If the key is a data variable, set the value. Otherwise, ignore it.

### set

    public Literal set(AtomDVariable key,
                       aterm.ATermAppl value)

### set

    public Individual set(AtomIObject key,
                          Individual value)

  If the key is an instance variable, set the value. Otherwise, ignore it.

### set

    public Individual set(AtomIVariable key,
                          aterm.ATermAppl value)

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004 Evren Sirin. All Rights Reserved.