src/main/java/org/iota/ict/ixi/model/Graph.java
public boolean isReferencing(String vertex, String hash) {
        if(vertex.equals(hash))
            return false;
        while(true) {
            Transaction transaction = transactionsByHash.get(vertex);
            if(transaction == null)
                return false;
            if(transaction.trunkHash().equals(hash) || transaction.branchHash().equals(hash))
                return true;
            vertex = transaction.trunkHash();
        }
    }
/**
     * Checks if a vertex fragment contains a specific trunk or branch
     * @param vertex the hash of the vertex tail
     * @param hash the branch or trunk that is to be checked
     * @return true if vertex contains hash
     * @return false if vertex does not contain hash
     */
Checks if a vertex fragment contains a specific trunk or branch
@param vertex the hash of the vertex tail
@param hash the branch or trunk that is to be checked
@return true if vertex contains hash
@return false if vertex does not contain hash
Checks if a vertex fragment contains a specific trunk or branch @param vertex the hash of the vertex tail @param hash the branch or trunk that is to be checked @return true if vertex contains hash @return false if vertex does not contain hash
public boolean isReferencing(String vertex, String hash) {
        if(vertex.equals(hash))
            return false;
        while(true) {
            Transaction transaction = transactionsByHash.get(vertex);
            if(transaction == null)
                return false;
            if(transaction.trunkHash().equals(hash) || transaction.branchHash().equals(hash))
                return true;
            vertex = transaction.trunkHash();
        }
    }
public boolean isReferencing ( String vertex , String hash ) { if ( vertex . equals ( hash ) ) return false ; while ( true ) { Transaction transaction = transactionsByHash . get ( vertex ) ; if ( transaction == null ) return false ; if ( transaction . trunkHash ( ) . equals ( hash ) || transaction . branchHash ( ) . equals ( hash ) ) return true ; vertex = transaction . trunkHash ( ) ; } }
Checks if a vertex fragment contains a specific trunk or branch
 @param vertex the hash of the vertex tail
 @param hash the branch or trunk that is to be checked
 @return true if vertex contains hash
 @return false if vertex does not contain hash
Checks if a vertex fragment contains a specific trunk or branch @param vertex the hash of the vertex tail @param hash the branch or trunk that is to be checked @return true if vertex contains hash @return false if vertex does not contain hash