public Object execute(Object[] parameters) { final DocumentDbParameterAccessor accessor = new DocumentDbParameterParameterAccessor(method, parameters); final Query query = createQuery(accessor); final ResultProcessor processor = method.getResultProcessor().withDynamicProjection(accessor); final String collection = ((DocumentDbEntityMetadata) method.getEntityInformation()).getCollectionName(); final DocumentDbQueryExecution execution = getExecution(query, accessor); return execution.execute(query, processor.getReturnedType().getDomainType(), collection); }
@Override public Object execute(Object[] parameters) { ParametersParameterAccessor accessor = new ParametersParameterAccessor(getQueryMethod().getParameters(), parameters); ResultProcessor resultProcessor = getQueryMethod().getResultProcessor().withDynamicProjection(accessor); Object source = executeInternal(accessor); return resultProcessor.processResult(source); }
@Override public Object execute(Object[] parameters) { ParameterAccessor accessor = new ParametersParameterAccessor(getQueryMethod().getParameters(), parameters); ResultProcessor processor = queryMethod.getResultProcessor().withDynamicProjection(accessor); return processor.processResult(doExecute(parameters)); }
/** * Creates an appropriate Ebean query from an {@link EbeanServer} according to the current {@link AbstractEbeanQuery} * type. * * @param queryString * @return */ protected Object createEbeanQuery(String queryString) { EbeanServer ebeanServer = getEbeanServer(); ResultProcessor resultFactory = getQueryMethod().getResultProcessor(); ReturnedType returnedType = resultFactory.getReturnedType(); return ebeanServer.createQuery(returnedType.getReturnedType(), queryString); }
protected EbeanQueryCreator createCreator(ParametersParameterAccessor accessor) { EbeanServer ebeanServer = getEbeanServer(); Query ebeanQuery = ebeanServer.createQuery(domainClass); ExpressionList expressionList = ebeanQuery.where(); ParameterMetadataProvider provider = new ParameterMetadataProvider(accessor); ResultProcessor processor = getQueryMethod().getResultProcessor(); return new EbeanQueryCreator(tree, processor.getReturnedType(), expressionList, provider); }
@Override protected Object createEbeanQuery(String queryString) { ResultProcessor resultFactory = getQueryMethod().getResultProcessor(); ReturnedType returnedType = resultFactory.getReturnedType(); return getEbeanServer().findNative(returnedType.getReturnedType(), queryString); }
@Override public Object execute(Object[] parameters) { ParameterAccessor accessor = new ParametersParameterAccessor(getQueryMethod().getParameters(), parameters); KeyValueQuery<?> query = prepareQuery(parameters); ResultProcessor processor = queryMethod.getResultProcessor().withDynamicProjection(accessor); return processor.processResult(doExecute(parameters, query)); }
private Object doExecute(MybatisQueryExecution execution, Object[] parameters) { Object result = execution.execute(this, parameters); ParametersParameterAccessor accessor = new ParametersParameterAccessor(method.getParameters(), parameters); ResultProcessor withDynamicProjection = method.getResultProcessor().withDynamicProjection(accessor); return withDynamicProjection.processResult(result, new TupleConverter(withDynamicProjection.getReturnedType())); }