private Set<Type> getTypes(Type type, boolean direct) {
        Set<Type> types = direct ? Sets.newHashSet(type) : type.subs().collect(toSet());
        return type.isImplicit() ?
                types.stream().flatMap(t -> Stream.of(t, tx.getType(Schema.ImplicitType.explicitLabel(t.label())))).collect(toSet()) :
                types;
    }
private Set < Type > getTypes ( Type type , boolean direct ) { Set < Type > types = direct ? Sets . newHashSet ( type ) : type . subs ( ) . collect ( toSet ( ) ) ; return type . isImplicit ( ) ? types . stream ( ) . flatMap ( t -> Stream . of ( t , tx . getType ( Schema . ImplicitType . explicitLabel ( t . label ( ) ) ) ) ) . collect ( toSet ( ) ) : types ; }
@param type of interest
@param direct true if type hierarchy shouldn't be included
@return relevant part (direct only or subs) of the type hierarchy of a type