private BackendExampleEntry createColorExample() {
    return new BackendExampleEntry() {
      @Override
      public AnimationBackend createBackend() {
        return ExampleColorBackend.createSampleColorAnimationBackend(
            mSpinner.getContext().getResources());
      }

      @Override
      public int getTitleResId() {
        return R.string.backend_color;
      }
    };
  }
Animation backend configurator that holds all sample animation backends.
samples/animation2/src/main/java/com/facebook/samples/animation2/utils/SampleAnimationBackendConfigurator.java