class SegmentKey {
    /** */
    private final ClusterNode node;

    /** */
    private final int segmentId;

    /**
     * Constructor.
     *
     * @param node Node.
     * @param segmentId Segment ID.
     */
    public SegmentKey(ClusterNode node, int segmentId) {
        assert node != null;

        this.node = node;
        this.segmentId = segmentId;
    }

    /**
     * @return Node.
     */
    public ClusterNode node() {
        return node;
    }

    /**
     * @return Segment ID.
     */
    public int segmentId() {
        return segmentId;
    }

    /** {@inheritDoc} */
    @Override public boolean equals(Object o) {<FILL_FUNCTION_BODY>}

    /** {@inheritDoc} */
    @Override public int hashCode() {
        int res = node.hashCode();

        res = 31 * res + segmentId;

        return res;
    }
}

        if (this == o)
            return true;

        if (o == null || getClass() != o.getClass())
            return false;

        SegmentKey key = (SegmentKey)o;

        return segmentId == key.segmentId && node.id().equals(key.node.id());

    
<no_super_class>