package com.capgemini.reports.snecmaobjects.rf;

import com.capgemini.framework.teamcenter.authent.TcSession;
import com.capgemini.reports.snecmaobjects.visitor.IComponentVisitor;
import com.capgemini.reports.snecmaobjects.visitor.IReceptorVisitor;
import com.teamcenter.soa.client.model.strong.ItemRevision;

import static com.capgemini.framework.teamcenter.object.types.SnecmaObjectTypes.RF_PART_ASSEMB_REVISION;

/**
 * Class representing a RFPartAssembRevision.
 */
public class RFPartAssembRevision extends AbstractRF {
    private static final long serialVersionUID = -7546817776977631474L;

    public RFPartAssembRevision(final TcSession session, final ItemRevision itemRevision) {
        super(session, itemRevision);
    }

    @Override
    public <T> T accept(final IReceptorVisitor<T> aReceptorVisitor) {
        return aReceptorVisitor.visitReceptor(this);
    }

    @Override
    public <T> T accept(final IComponentVisitor<T> aComponentVisitor) {
        return aComponentVisitor.visitComponent(this);
    }

    @Override
    public boolean isSuperModel() {
        return false;
    }

    @Override
    public boolean isRFPartOrPartAssemb() {
        return true;
    }

    @Override
    public String toString() {
        return RF_PART_ASSEMB_REVISION + " " + this.getItemId();
    }
}
