本文整理汇总了Java中org.apache.ibatis.annotations.ConstructorArgs类的典型用法代码示例。如果您正苦于以下问题:Java ConstructorArgs类的具体用法?Java ConstructorArgs怎么用?Java ConstructorArgs使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ConstructorArgs类属于org.apache.ibatis.annotations包,在下文中一共展示了ConstructorArgs类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: parseResultMap
import org.apache.ibatis.annotations.ConstructorArgs; //导入依赖的package包/类
private String parseResultMap(Method method) {
Class<?> returnType = getReturnType(method);
ConstructorArgs args = method.getAnnotation(ConstructorArgs.class);
Results results = method.getAnnotation(Results.class);
TypeDiscriminator typeDiscriminator = method.getAnnotation(TypeDiscriminator.class);
String resultMapId = generateResultMapName(method);
applyResultMap(resultMapId, returnType, argsIf(args), resultsIf(results), typeDiscriminator);
return resultMapId;
}
开发者ID:Caratacus,项目名称:mybatis-plus-mini,代码行数:10,代码来源:MybatisMapperAnnotationBuilder.java
示例2: parseResultMap
import org.apache.ibatis.annotations.ConstructorArgs; //导入依赖的package包/类
private String parseResultMap(Method method) {
Class<?> returnType = getReturnType(method);
ConstructorArgs args = method.getAnnotation(ConstructorArgs.class);
Results results = method.getAnnotation(Results.class);
TypeDiscriminator typeDiscriminator = method.getAnnotation(TypeDiscriminator.class);
String resultMapId = generateResultMapName(method);
applyResultMap(resultMapId, returnType, argsIf(args), resultsIf(results), typeDiscriminator);
return resultMapId;
}
开发者ID:yuexiahandao,项目名称:MybatisCode,代码行数:10,代码来源:MapperAnnotationBuilder.java
示例3: argsIf
import org.apache.ibatis.annotations.ConstructorArgs; //导入依赖的package包/类
private Arg[] argsIf(ConstructorArgs args) {
return args == null ? new Arg[0] : args.value();
}
开发者ID:Caratacus,项目名称:mybatis-plus-mini,代码行数:4,代码来源:MybatisMapperAnnotationBuilder.java
示例4: argsIf
import org.apache.ibatis.annotations.ConstructorArgs; //导入依赖的package包/类
private Arg[] argsIf(ConstructorArgs args) {
return args == null ? new Arg[0] : args.value();
}
开发者ID:yuexiahandao,项目名称:MybatisCode,代码行数:4,代码来源:MapperAnnotationBuilder.java
示例5: getProductByNameUsingConstructor
import org.apache.ibatis.annotations.ConstructorArgs; //导入依赖的package包/类
@Select("select id, name from product where name = #{value}")
@ConstructorArgs({
@Arg(id = true, column="id", javaType = ProductId.class, jdbcType=JdbcType.INTEGER),
@Arg(column="name")
})
Product getProductByNameUsingConstructor(String name);
开发者ID:yuexiahandao,项目名称:MybatisCode,代码行数:7,代码来源:Mapper.java
示例6: selectWordCountTopN
import org.apache.ibatis.annotations.ConstructorArgs; //导入依赖的package包/类
/**
* 查询词频统计结果,查询频次开前的N个结果
*/
@Select("SELECT `word`,`count` FROM `wordcount` ORDER BY `count` DESC LIMIT #{N}")
@ConstructorArgs(value = { @Arg(column = "word", javaType = String.class),
@Arg(column = "count", javaType = Integer.class) })
@ResultType(value = WordAndCount.class)
public List<WordAndCount> selectWordCountTopN(int N);
开发者ID:huge-data,项目名称:storm-sentiment,代码行数:9,代码来源:WordCountDao.java
示例7: select
import org.apache.ibatis.annotations.ConstructorArgs; //导入依赖的package包/类
@ConstructorArgs({
@Arg(column = "id", name = "noSuchConstructorArg"),
})
@Select("select * from users ")
User select();
开发者ID:mybatis,项目名称:mybatis-3,代码行数:6,代码来源:InvalidNamedConstructorArgsTest.java
注:本文中的org.apache.ibatis.annotations.ConstructorArgs类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论