本文整理匯總了Java中com.datastax.driver.core.Row.getSet方法的典型用法代碼示例。如果您正苦於以下問題:Java Row.getSet方法的具體用法?Java Row.getSet怎麽用?Java Row.getSet使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.datastax.driver.core.Row
的用法示例。
在下文中一共展示了Row.getSet方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: load
import com.datastax.driver.core.Row; //導入方法依賴的package包/類
@Override
public Data load(Data data, Row row) {
// Int more efficient
data.ns = row.getString(0);
data.name = row.getString(1);
data.perms = row.getSet(2,String.class);
data.description = row.getString(3);
return data;
}
示例2: load
import com.datastax.driver.core.Row; //導入方法依賴的package包/類
@Override
public Data load(Data data, Row row) {
// Int more efficient Match "fields" string
data.ns = row.getString(0);
data.type = row.getString(1);
data.instance = row.getString(2);
data.action = row.getString(3);
data.roles = row.getSet(4,String.class);
data.description = row.getString(5);
return data;
}
示例3: load
import com.datastax.driver.core.Row; //導入方法依賴的package包/類
@Override
public Data load(Data data, Row row) {
data.mechid = row.getString(0);
data.machine = row.getString(1);
data.type = row.getSet(2, String.class);
data.sponsor = row.getString(3);
data.ca = row.getString(4);
data.dir = row.getString(5);
data.appName = row.getString(6);
data.os_user = row.getString(7);
data.notify = row.getString(8);
data.expires = row.getDate(9);
data.renewDays = row.getInt(10);
return data;
}
示例4: load
import com.datastax.driver.core.Row; //導入方法依賴的package包/類
private static void load(Trans trans, Session session, String query) {
//
trans.info().log( "query: " + query );
TimeTaken tt = trans.start("Read Perms", Env.REMOTE);
ResultSet results;
try {
Statement stmt = new SimpleStatement( query );
results = session.execute(stmt);
} finally {
tt.done();
}
try {
Iterator<Row> iter = results.iterator();
Row row;
tt = trans.start("Load Perms", Env.SUB);
try {
while(iter.hasNext()) {
row = iter.next();
Perm pk = new Perm(row.getString(0),row.getString(1),row.getString(2),row.getString(3), row.getString(4), row.getSet(5,String.class));
keys.put(pk.encode(), pk);
data.put(pk,pk.roles);
}
} finally {
tt.done();
}
} finally {
trans.info().log("Found",data.size(),"perms");
}
}
示例5: load
import com.datastax.driver.core.Row; //導入方法依賴的package包/類
private static void load(Trans trans, Session session, String query) {
trans.info().log( "query: " + query );
TimeTaken tt = trans.start("Read Roles", Env.REMOTE);
ResultSet results;
try {
Statement stmt = new SimpleStatement( query );
results = session.execute(stmt);
} finally {
tt.done();
}
try {
Iterator<Row> iter = results.iterator();
Row row;
tt = trans.start("Load Roles", Env.SUB);
try {
while(iter.hasNext()) {
row = iter.next();
Role rk =new Role(row.getString(0),row.getString(1), row.getString(2),row.getSet(3,String.class));
keys.put(rk.encode(), rk);
data.put(rk,rk.perms);
}
} finally {
tt.done();
}
} finally {
trans.info().log("Found",data.size(),"roles");
}
}