code: private <T> Map<PrimitivePropertyMethodMetadata<PropertyMetadata>, Object> prepareExample(Example<T> example, Class<?> type, Class<?>... types) {
          Map<PrimitivePropertyMethodMetadata<PropertyMetadata>, Object> exampleEntity = new HashMap<>();
          ExampleProxyMethodService<T> proxyMethodService = (ExampleProxyMethodService<T>) exampleProxyMethodServices.get(type);
          if (proxyMethodService == null) {
              proxyMethodService = new ExampleProxyMethodService(type, sessionContext);
              exampleProxyMethodServices.put(type, proxyMethodService);
          }
          InstanceInvocationHandler invocationHandler = new InstanceInvocationHandler(exampleEntity, proxyMethodService);
          List<Class<?>> effectiveTypes = new ArrayList<>(types.length + 1);
          effectiveTypes.add(type);
          effectiveTypes.addAll(Arrays.asList(types));
          CompositeType compositeType = CompositeTypeBuilder.create(CompositeObject.class, type, types);
          T instance = sessionContext.getProxyFactory().createInstance(invocationHandler, compositeType);
          example.prepare(instance);
          return exampleEntity;
      }
docs: Setup an example entity.
  
  @param type
  The type.
  @param example
  The provided example.
  @param <T>
  The type.
  @return The example.