本文整理了Java中org.skife.jdbi.v2.sqlobject.Bind
类的一些代码示例,展示了Bind
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Bind
类的具体详情如下:
包路径:org.skife.jdbi.v2.sqlobject.Bind
类名称:Bind
暂无
代码示例来源:origin: killbill/killbill
@SqlUpdate
@Audited(ChangeType.UPDATE)
public void updateBundleLastSysTime(@Bind("id") String id,
@Bind("lastSysUpdateDate") Date lastSysUpdate,
@SmartBindBean final InternalCallContext context);
代码示例来源:origin: signalapp/Signal-Server
@Mapper(MessageMapper.class)
@SqlQuery("DELETE FROM messages WHERE " + ID + " IN (SELECT " + ID + " FROM messages WHERE " + DESTINATION + " = :destination AND " + DESTINATION_DEVICE + " = :destination_device AND " + SOURCE + " = :source AND " + TIMESTAMP + " = :timestamp ORDER BY " + ID + " LIMIT 1) RETURNING *")
abstract OutgoingMessageEntity remove(@Bind("destination") String destination,
@Bind("destination_device") long destinationDevice,
@Bind("source") String source,
@Bind("timestamp") long timestamp);
代码示例来源:origin: killbill/killbill
@SqlQuery
public CatalogOverrideBlockDefinitionModelDao getByAttributes(@Bind("parentUnitName") final String parentUnitName,
@Bind("currency") final String currency,
@Bind("price") final BigDecimal price,
@Bind("max") final double max,
@Bind("size") final double size,
@SmartBindBean final InternalTenantContext context);
代码示例来源:origin: org.kill-bill.commons/killbill-queue
@SqlUpdate
int claimEntry(@Bind("recordId") Long id,
@Bind("now") Date now,
@Bind("owner") String owner,
@Bind("nextAvailable") Date nextAvailable,
@Define("tableName") final String tableName);
代码示例来源:origin: killbill/killbill
@SqlQuery
public UUID getIdFromObject(@Bind("recordId") Long recordId, @Define("tableName") final String tableName);
代码示例来源:origin: killbill/killbill
@SqlQuery
@SmartFetchSize(shouldStream = true)
public Iterator<M> search(@Bind("searchKey") final String searchKey,
@Bind("likeSearchKey") final String likeSearchKey,
@Bind("offset") final Long offset,
@Bind("rowCount") final Long rowCount,
@Define("ordering") final String ordering,
@SmartBindBean final InternalTenantContext context);
代码示例来源:origin: killbill/killbill
@SqlUpdate
public void updatePassword(@Bind("username") String username,
@Bind("password") String password,
@Bind("passwordSalt") String passwordSalt,
@Bind("updatedDate") Date updatedDate,
@Bind("updatedBy") String updatedBy);
代码示例来源:origin: signalapp/Signal-Server
@Mapper(MessageMapper.class)
@SqlUpdate("DELETE FROM messages WHERE " + ID + " = :id AND " + DESTINATION + " = :destination")
abstract void remove(@Bind("destination") String destination, @Bind("id") long id);
代码示例来源:origin: killbill/killbill
@SqlUpdate
@Audited(ChangeType.UPDATE)
public void unactiveEvent(@Bind("recordId") final Long recordId,
@Bind("createdDate") final DateTime createdDate,
@Bind("createdBy") final String createdBy);
代码示例来源:origin: killbill/killbill
private List<String> retrieveEntityIdsFromArguments(final Method method, final Object[] args) {
final Annotation[][] parameterAnnotations = getAnnotations(method);
int i = -1;
for (final Object arg : args) {
i++;
// Assume the first argument of type Entity is our type of Entity (type U here)
// This is true for e.g. create calls
if (arg instanceof Entity) {
return ImmutableList.<String>of(((Entity) arg).getId().toString());
}
// For Batch calls, the first argument will be of type List<Entity>
if (arg instanceof Iterable) {
final Builder<String> entityIds = extractEntityIdsFromBatchArgument((Iterable) arg);
if (entityIds != null) {
return entityIds.build();
}
}
for (final Annotation annotation : parameterAnnotations[i]) {
if (arg instanceof String && Bind.class.equals(annotation.annotationType()) && ("id").equals(((Bind) annotation).value())) {
return ImmutableList.<String>of((String) arg);
} else if (arg instanceof Collection && BindIn.class.equals(annotation.annotationType()) && ("ids").equals(((BindIn) annotation).value())) {
return ImmutableList.<String>copyOf((Collection) arg);
}
}
}
return ImmutableList.<String>of();
}
代码示例来源:origin: com.ning.billing/killbill-osgi-bundles-analytics
public Binder build(Annotation annotation)
{
Bind bind = (Bind) annotation;
try {
return bind.binder().newInstance();
}
catch (Exception e) {
throw new IllegalStateException("unable to instantiate specified binder", e);
}
}
}
代码示例来源:origin: signalapp/Signal-Server
@Mapper(MessageMapper.class)
@SqlQuery("SELECT * FROM messages WHERE " + DESTINATION + " = :destination AND " + DESTINATION_DEVICE + " = :destination_device ORDER BY " + TIMESTAMP + " ASC LIMIT " + RESULT_SET_CHUNK_SIZE)
abstract List<OutgoingMessageEntity> load(@Bind("destination") String destination,
@Bind("destination_device") long destinationDevice);
代码示例来源:origin: killbill/killbill
@SqlQuery
public List<CatalogOverridePhaseDefinitionModelDao> getByAttributes(@Bind("parentPhaseName") String parentPhaseName,
@Bind("currency") String currency,
@Bind("fixedPrice") BigDecimal fixedPrice,
@Bind("recurringPrice") BigDecimal recurringPrice,
@SmartBindBean final InternalTenantContext context);
代码示例来源:origin: org.kill-bill.commons/killbill-queue
@SqlUpdate
void updateEntry(@Bind("recordId") Long id,
@Bind("eventJson") String eventJson,
@Bind("searchKey1") final Long searchKey1,
@Bind("searchKey2") final Long searchKey2,
@Define("tableName") final String tableName);
}
代码示例来源:origin: killbill/killbill
@SqlQuery
public Long getAccountRecordIdFromObjectOtherThanAccount(@Bind("id") String id, @Define("tableName") final String tableName);
代码示例来源:origin: killbill/killbill
@SqlQuery
public List<EntityHistoryModelDao<M, E>> getHistoryForTargetRecordId(@Define("bypassMappingRegistryCache") final boolean bypassMappingRegistryCache,
@Bind("targetRecordId") final long targetRecordId,
@SmartBindBean InternalTenantContext context);
@SqlUpdate
代码示例来源:origin: killbill/killbill
@SqlUpdate
public void invalidate(@Bind("username") String username,
@Bind("roleName") String roleName,
@Bind("updatedDate") final Date updatedDate,
@Bind("updatedBy") final String updatedBy);
}
代码示例来源:origin: org.kill-bill.commons/killbill-jdbi
@Override
public void bind(SQLStatement q, Bind b, Object arg)
{
q.bind(b.value(), arg);
}
代码示例来源:origin: org.kill-bill.commons/killbill-jdbi
@Override
public Binder build(Annotation annotation)
{
Bind bind = (Bind) annotation;
try {
return bind.binder().newInstance();
}
catch (Exception e) {
throw new IllegalStateException("unable to instantiate specified binder", e);
}
}
}
代码示例来源:origin: killbill/killbill
@SqlUpdate
@Audited(ChangeType.UPDATE)
public Object updatePaymentMethod(@Bind("id") String accountId,
@Bind("paymentMethodId") String paymentMethodId,
@SmartBindBean final InternalCallContext context);
内容来源于网络,如有侵权,请联系作者删除!