@Test public void renameColumnTest() { BasicDBObject expected = new BasicDBObject("$rename", new BasicDBObject("old", "new")); Assert.assertEquals("The command is not the expected", expected, AlterOptionsUtils.buildRenameColumnDBObject("old", "new")); }
public static DBObject buildRenameColumnDBObject(String oldName, String newName) { return new BasicDBObject(RENAME_COMMAND, new BasicDBObject(oldName, newName)); }
AlterOptionsUtils { public static DBObject buildRenameColumnDBObject(String oldName, String newName) { return new BasicDBObject(RENAME_COMMAND, new BasicDBObject(oldName, newName)); } }
AlterOptionsUtils { public static DBObject buildRenameColumnDBObject(String oldName, String newName) { return new BasicDBObject(RENAME_COMMAND, new BasicDBObject(oldName, newName)); } private  AlterOptionsUtils(); }
AlterOptionsUtils { public static DBObject buildRenameColumnDBObject(String oldName, String newName) { return new BasicDBObject(RENAME_COMMAND, new BasicDBObject(oldName, newName)); } private  AlterOptionsUtils(); static DBObject buildRenameColumnDBObject(String oldName, String newName); static DBObject buildDropColumnDBObject(String name); }
AlterOptionsUtils { public static DBObject buildRenameColumnDBObject(String oldName, String newName) { return new BasicDBObject(RENAME_COMMAND, new BasicDBObject(oldName, newName)); } private  AlterOptionsUtils(); static DBObject buildRenameColumnDBObject(String oldName, String newName); static DBObject buildDropColumnDBObject(String name); static final String RENAME_COMMAND; static final String DROP_COMMAND; }