Java 类org.apache.ibatis.annotations.MapKey 实例源码

项目:MybatisCode    文件:MapperMethod.java   
private String getMapKey(Method method) {
  String mapKey = null;
  if (Map.class.isAssignableFrom(method.getReturnType())) {
    final MapKey mapKeyAnnotation = method.getAnnotation(MapKey.class);
    if (mapKeyAnnotation != null) {
      mapKey = mapKeyAnnotation.value();
    }
  }
  return mapKey;
}
项目:mybatis    文件:MapperMethod.java   
private String getMapKey(Method method) {
  String mapKey = null;
  if (Map.class.isAssignableFrom(method.getReturnType())) {
    final MapKey mapKeyAnnotation = method.getAnnotation(MapKey.class);
    if (mapKeyAnnotation != null) {
      mapKey = mapKeyAnnotation.value();
    }
  }
  return mapKey;
}
项目:mybaties    文件:MapperMethod.java   
private String getMapKey(Method method) {
  String mapKey = null;
  if (Map.class.isAssignableFrom(method.getReturnType())) {
    //如果返回类型是map类型的,查看该method是否有MapKey注解。如果有这个注解,将这个注解的值作为map的key
    final MapKey mapKeyAnnotation = method.getAnnotation(MapKey.class);
    if (mapKeyAnnotation != null) {
      mapKey = mapKeyAnnotation.value();
    }
  }
  return mapKey;
}
项目:play    文件:MapperMethod.java   
private String getMapKey(Method method) {
  String mapKey = null;
  if (Map.class.isAssignableFrom(method.getReturnType())) {
    final MapKey mapKeyAnnotation = method.getAnnotation(MapKey.class);
    if (mapKeyAnnotation != null) {
      mapKey = mapKeyAnnotation.value();
    }
  }
  return mapKey;
}
项目:mybatis-3    文件:MapperMethod.java   
private String getMapKey(Method method) {
  String mapKey = null;
  if (Map.class.isAssignableFrom(method.getReturnType())) {
    final MapKey mapKeyAnnotation = method.getAnnotation(MapKey.class);
    if (mapKeyAnnotation != null) {
      mapKey = mapKeyAnnotation.value();
    }
  }
  return mapKey;
}
项目:MybatisCode    文件:BaseMapper.java   
@SelectProvider(type = StatementProvider.class, method = "provideSelect")
@MapKey("id")
Map<T, S> selectMap(S param);
项目:MybatisCode    文件:Mapper.java   
@Select("select id, name from users")
@MapKey("id")
Map<Integer, User<String>> getAMapOfUsers();
项目:MybatisCode    文件:PersonMapper.java   
@Select("select * from person")
@MapKey("id")
Map<Integer, Person> selectAsMap();
项目:mybatis    文件:BaseMapper.java   
@SelectProvider(type = StatementProvider.class, method = "provideSelect")
@MapKey("id")
Map<T, S> selectMap(S param);
项目:mybatis    文件:Mapper.java   
@Select("select id, name from users")
@MapKey("id")
Map<Integer, User<String>> getAMapOfUsers();
项目:mybatis    文件:PersonMapper.java   
@Select("select * from person")
@MapKey("id")
Map<Integer, Person> selectAsMap();
项目:meazza    文件:DefaultMyBatisBasicDao.java   
@SuppressWarnings("unchecked")
@Override
@MapKey("id")
public <PK> Map<PK, T> findMap(PK... ids) {
    return getSqlSession().selectMap("findMap", ids, "id");
}
项目:meazza    文件:MyBatisBasicDao.java   
@SuppressWarnings("unchecked")
@MapKey("id")
<PK> Map<PK, T> findMap(PK... ids);
项目:mybaties    文件:Mapper.java   
@Select("select id, name from users")
@MapKey("id")
Map<Integer, User<String>> getAMapOfUsers();
项目:mybaties    文件:PersonMapper.java   
@Select("select * from person")
@MapKey("id")
Map<Integer, Person> selectAsMap();
项目:play    文件:Mapper.java   
@Select("select id, name from users")
@MapKey("id")
Map<Integer, User<String>> getAMapOfUsers();
项目:play    文件:PersonMapper.java   
@Select("select * from person")
@MapKey("id")
Map<Integer, Person> selectAsMap();
项目:mybatis-3    文件:BaseMapper.java   
@SelectProvider(type = StatementProvider.class, method = "provideSelect")
@MapKey("id")
Map<T, S> selectMap(S param);
项目:mybatis-3    文件:Mapper.java   
@Select("select id, name from users")
@MapKey("id")
Map<Integer, User<String>> getAMapOfUsers();
项目:mybatis-3    文件:PersonMapper.java   
@Select("select * from person")
@MapKey("id")
Map<Integer, Person> selectAsMap();