s.setLongGen(((LongGenMgr) longGenMgr).getLongGen(s.getName()));
} else {
//else, use rdb_sequence_long_gen
if (mapperRdb != null) {
if (s.getLongGen() == null) {
RdbSequenceLongGen rdbLongGen = new RdbSequenceLongGen(mapperRdb, s.datastoreName, false);
if(s.start != null) {
rdbLongGen.setSequenceStart(s.start);
}
if(s.increment != null) {
rdbLongGen.setSequenceIncrement(s.increment);
}
if(s.cache != null) {
rdbLongGen.setSequenceStart(s.cache);
}
//create it
Object conn = mapperRdb.getConnection();
rdbLongGen.createSequence(conn);
//and associate it to the sequence
s.setLongGen(rdbLongGen);
//close the connection
mapperRdb.closeConnection(conn);
}