Class ProductUtil


  • public final class ProductUtil
    extends java.lang.Object
    Utility for performing reoccuring operations on products.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static <T extends ProductIntent>
      T
      getIntent​(Product product, java.lang.Class<T> productIntent)
      Retrieve a specific intent from a product.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • getIntent

        public static <T extends ProductIntent> T getIntent​(Product product,
                                                            java.lang.Class<T> productIntent)
        Retrieve a specific intent from a product.
        Type Parameters:
        T - Type of the intent.
        Parameters:
        product - Product te read intent from.
        productIntent - Type of the intent.
        Returns:
        Requested Intent or null if no matching intent was found.