net.sf.sdedit.util
Class Bijection<P,I>

java.lang.Object
  extended by net.sf.sdedit.util.Bijection<P,I>
Type Parameters:
P - the type of the pre-images
I - the type of the images

public class Bijection<P,I>
extends Object

Author:
Markus Strauch

Constructor Summary
Bijection()
          Constructor.
 
Method Summary
 void add(P preImage, I image)
          Adds a pair of a pre-image and an image to the bijection.
 I getImage(P preImage)
          Returns the image of the given pre-image
 P getPreImage(I image)
          Returns the pre-image of the given image
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Bijection

public Bijection()
Constructor.

Method Detail

add

public void add(P preImage,
                I image)
Adds a pair of a pre-image and an image to the bijection.

Parameters:
preImage - the pre-image
image - the image

getImage

public I getImage(P preImage)
Returns the image of the given pre-image

Parameters:
preImage -
Returns:

getPreImage

public P getPreImage(I image)
Returns the pre-image of the given image

Parameters:
image -
Returns:


Copyright © 2011. All Rights Reserved.