public static < T extends Entity > Optional < T > anyEntityOfType ( final EntityContainer container , final Class < T > type ) { return container . streamEntitiesOfType ( type ) . findAny ( ) ; }
Gets any entity within the container marked with the specified type .