All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.sf.jrtps.udds.Entity Maven / Gradle / Ivy

There is a newer version: 1.5.1
Show newest version
package net.sf.jrtps.udds;

/**
 * Entity is a base class for DataReader and DataWriter.
 * 
 * @author mcr70
 * @param 
 * 
 */
public class Entity {
    private final String topicName;
    private final Participant participant;
    private final Class type;

    /**
     * Constructor
     * 
     * @param topicName
     *            name of the topic this entity is bound to.
     */
    protected Entity(Participant p, Class type, String topicName) {
        this.participant = p;
        this.type = type;
        this.topicName = topicName;
    }

    /**
     * Get the name of the topic of this entity.
     * 
     * @return topic name
     */
    public String getTopicName() {
        return topicName;
    }

    /**
     * Get the Participant that has created this Entity.
     * 
     * @return Participant
     */
    public Participant getParticipant() {
        return participant;
    }

    /**
     * Gets the type associated with this entity.
     * 
     * @return Class
     */
    public Class getType() {
        return type;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy