// Path: src/main/java/ru/shadam/tarantool/repository/query/TarantoolQueryCreator.java
// public class TarantoolQueryCreator extends AbstractQueryCreator<KeyValueQuery<TarantoolQuery>, TarantoolQuery> {
// 
//     public TarantoolQueryCreator(PartTree tree, ParameterAccessor parameters) {
//         super(tree, parameters);
//     }
// 
//     @Override
//     protected TarantoolQuery create(Part part, Iterator<Object> iterator) {
//         switch (part.getType()) {
//             case SIMPLE_PROPERTY:
//                 return new TarantoolQuery(part.getProperty().toDotPath(), iterator.next());
//             default:
//                 throw new IllegalArgumentException(part.getType() + "is not supported for redis query derivation");
//         }
//     }
// 
//     @Override
//     protected TarantoolQuery and(Part part, TarantoolQuery base, Iterator<Object> iterator) {
//         throw new UnsupportedOperationException("and is not supported");
//     }
// 
//     @Override
//     protected TarantoolQuery or(TarantoolQuery base, TarantoolQuery criteria) {
//         throw new UnsupportedOperationException("or is not supported");
//     }
// 
//     @Override
//     protected KeyValueQuery<TarantoolQuery> complete(TarantoolQuery criteria, Sort sort) {
//         final KeyValueQuery<TarantoolQuery> tarantoolQueryKeyValueQuery = new KeyValueQuery<>(criteria);
//         tarantoolQueryKeyValueQuery.setSort(sort);
//         return tarantoolQueryKeyValueQuery;
//     }
// }
// 
// Path: src/main/java/ru/shadam/tarantool/repository/support/TarantoolRepositoryFactoryBean.java
// public class TarantoolRepositoryFactoryBean<T extends Repository<S, ID>, S, ID extends Serializable>
//         extends KeyValueRepositoryFactoryBean<T, S, ID> {
// 
//     /*
//      * (non-Javadoc)
//      * @see org.springframework.data.keyvalue.repository.support.KeyValueRepositoryFactoryBean#createRepositoryFactory(org.springframework.data.keyvalue.core.KeyValueOperations, java.lang.Class, java.lang.Class)
//      */
//     @Override
//     protected TarantoolRepositoryFactory createRepositoryFactory(
//             KeyValueOperations operations,
//             Class<? extends AbstractQueryCreator<?, ?>> queryCreator,
//             Class<? extends RepositoryQuery> repositoryQueryType
//     ) {
//         return new TarantoolRepositoryFactory(operations, queryCreator, repositoryQueryType);
//     }
// }


import org.springframework.beans.factory.FactoryBean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Import;
import org.springframework.data.keyvalue.core.KeyValueOperations;
import org.springframework.data.keyvalue.repository.config.QueryCreatorType;
import ru.shadam.tarantool.repository.query.TarantoolQueryCreator;
import ru.shadam.tarantool.repository.support.TarantoolRepositoryFactoryBean;
import java.lang.annotation.*;
package ru.shadam.tarantool.repository.configuration;



/**
 * @author sala
 */
@Target(ElementType.TYPE)
@Retention(RetentionPolicy.RUNTIME)
@Documented
@Inherited
@Import(TarantoolRepositoriesRegistrar.class)
// Path: src/main/java/ru/shadam/tarantool/repository/query/TarantoolQueryCreator.java
// public class TarantoolQueryCreator extends AbstractQueryCreator<KeyValueQuery<TarantoolQuery>, TarantoolQuery> {
// 
//     public TarantoolQueryCreator(PartTree tree, ParameterAccessor parameters) {
//         super(tree, parameters);
//     }
// 
//     @Override
//     protected TarantoolQuery create(Part part, Iterator<Object> iterator) {
//         switch (part.getType()) {
//             case SIMPLE_PROPERTY:
//                 return new TarantoolQuery(part.getProperty().toDotPath(), iterator.next());
//             default:
//                 throw new IllegalArgumentException(part.getType() + "is not supported for redis query derivation");
//         }
//     }
// 
//     @Override
//     protected TarantoolQuery and(Part part, TarantoolQuery base, Iterator<Object> iterator) {
//         throw new UnsupportedOperationException("and is not supported");
//     }
// 
//     @Override
//     protected TarantoolQuery or(TarantoolQuery base, TarantoolQuery criteria) {
//         throw new UnsupportedOperationException("or is not supported");
//     }
// 
//     @Override
//     protected KeyValueQuery<TarantoolQuery> complete(TarantoolQuery criteria, Sort sort) {
//         final KeyValueQuery<TarantoolQuery> tarantoolQueryKeyValueQuery = new KeyValueQuery<>(criteria);
//         tarantoolQueryKeyValueQuery.setSort(sort);
//         return tarantoolQueryKeyValueQuery;
//     }
// }
// 
// Path: src/main/java/ru/shadam/tarantool/repository/support/TarantoolRepositoryFactoryBean.java
// public class TarantoolRepositoryFactoryBean<T extends Repository<S, ID>, S, ID extends Serializable>
//         extends KeyValueRepositoryFactoryBean<T, S, ID> {
// 
//     /*
//      * (non-Javadoc)
//      * @see org.springframework.data.keyvalue.repository.support.KeyValueRepositoryFactoryBean#createRepositoryFactory(org.springframework.data.keyvalue.core.KeyValueOperations, java.lang.Class, java.lang.Class)
//      */
//     @Override
//     protected TarantoolRepositoryFactory createRepositoryFactory(
//             KeyValueOperations operations,
//             Class<? extends AbstractQueryCreator<?, ?>> queryCreator,
//             Class<? extends RepositoryQuery> repositoryQueryType
//     ) {
//         return new TarantoolRepositoryFactory(operations, queryCreator, repositoryQueryType);
//     }
// }


// Path: src/main/java/ru/shadam/tarantool/repository/configuration/EnableTarantoolRepositories.java
import org.springframework.beans.factory.FactoryBean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Import;
import org.springframework.data.keyvalue.core.KeyValueOperations;
import org.springframework.data.keyvalue.repository.config.QueryCreatorType;
import ru.shadam.tarantool.repository.query.TarantoolQueryCreator;
import ru.shadam.tarantool.repository.support.TarantoolRepositoryFactoryBean;
import java.lang.annotation.*;

package ru.shadam.tarantool.repository.configuration;



/**
 * @author sala
 */
@Target(ElementType.TYPE)
@Retention(RetentionPolicy.RUNTIME)
@Documented
@Inherited
@Import(TarantoolRepositoriesRegistrar.class)
@QueryCreatorType(TarantoolQueryCreator.class)