type stringclasses 1
value | dataset stringclasses 1
value | input stringlengths 75 160k | instruction stringlengths 117 171 | output stringlengths 88 168k |
|---|---|---|---|---|
Inversion-Mutation | megadiff | "@Override
public void onEnable() {
instance = this;
configManager = new ConfigManager();
groupMediator = new GroupMediator();
jaLogger = new JukeAlertLogger();
snitchManager = new SnitchManager();
registerEvents();
registerCommands();
snitchManager.loadSnitches();
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "onEnable" | "@Override
public void onEnable() {
instance = this;
configManager = new ConfigManager();
jaLogger = new JukeAlertLogger();
snitchManager = new SnitchManager();
<MASK>groupMediator = new GroupMediator();</MASK>
registerEvents();
registerCommands();
snitchManager.loadSnitches();
}" |
Inversion-Mutation | megadiff | "public void setContent(String content)
{
// SAK-2470
if (this.content == null) this.content = "";
this.content= content.replaceAll("[\\x00-\\x08\\x0b\\x0c\\x0e-\\x1f\\ud800-\\udfff\\uffff\\ufffe]", "");
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "setContent" | "public void setContent(String content)
{
<MASK>this.content= content.replaceAll("[\\x00-\\x08\\x0b\\x0c\\x0e-\\x1f\\ud800-\\udfff\\uffff\\ufffe]", "");</MASK>
// SAK-2470
if (this.content == null) this.content = "";
}" |
Inversion-Mutation | megadiff | "public void statusChanged(DifferenceEvent event) {
if (event == DifferenceEvent.DIFF_COMPLETED) {
renderer = RenderingService.get(diffs.getEngine());
fillEntityBasedDiffList();
}
else if (event == DifferenceEvent.DIFF_RESET) {
entityBasedDiffList.removeAll();
diffModel.clear();
}
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "statusChanged" | "public void statusChanged(DifferenceEvent event) {
if (event == DifferenceEvent.DIFF_COMPLETED) {
<MASK>fillEntityBasedDiffList();</MASK>
renderer = RenderingService.get(diffs.getEngine());
}
else if (event == DifferenceEvent.DIFF_RESET) {
entityBasedDiffList.removeAll();
diffModel.cle... |
Inversion-Mutation | megadiff | "protected void endTextObject() {
if (textutil.isInTextObject()) {
textutil.endTextObject();
if (this.inMarkedContentSequence) {
endMarkedContentSequence();
}
}
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "endTextObject" | "protected void endTextObject() {
if (textutil.isInTextObject()) {
if (this.inMarkedContentSequence) {
endMarkedContentSequence();
}
<MASK>textutil.endTextObject();</MASK>
}
}" |
Inversion-Mutation | megadiff | "public void destroy() {
super.destroy();
LinuxDisplay.lockAWT();
LinuxDisplay.decDisplay();
GLContext.unloadOpenGLLibrary();
LinuxDisplay.unlockAWT();
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "destroy" | "public void destroy() {
super.destroy();
LinuxDisplay.lockAWT();
<MASK>GLContext.unloadOpenGLLibrary();</MASK>
LinuxDisplay.decDisplay();
LinuxDisplay.unlockAWT();
}" |
Inversion-Mutation | megadiff | "public void build() throws Exception {
names = new Hashtable();
int access = superclass.getModifiers();
if ((access & Modifier.FINAL) != 0) {
throw new InstantiationException("can't subclass final class");
}
access = Modifier.PUBLIC | Modifier.SYNCHRONIZED;
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "build" | "public void build() throws Exception {
names = new Hashtable();
int access = superclass.getModifiers();
if ((access & Modifier.FINAL) != 0) {
throw new InstantiationException("can't subclass final class");
}
access = Modifier.PUBLIC | Modifier.SYNCHRONIZED;
... |
Inversion-Mutation | megadiff | "@Override
public PS3ControllerState read() throws IOException
{
int n = dev.read(buf);
if(n != EXPECTED_BUFSIZE && n != EXPECTED_BUFSIZE_2)
{
throw new IOException("Received packed with unexpected size " + n);
}
BitSet bs = new BitSet(24);
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "read" | "@Override
public PS3ControllerState read() throws IOException
{
int n = dev.read(buf);
if(n != EXPECTED_BUFSIZE && n != EXPECTED_BUFSIZE_2)
{
throw new IOException("Received packed with unexpected size " + n);
}
BitSet bs = new BitSet(24);
... |
Inversion-Mutation | megadiff | "@Override
public void onReceive(final Context context, Intent intent) {
final String action = intent.getAction();
if (Log.LOGV) Log.v("AlarmInitReceiver" + action);
final PendingResult result = goAsync();
final WakeLock wl = AlarmAlertWakeLock.createPartialWakeLock(context);
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "onReceive" | "@Override
public void onReceive(final Context context, Intent intent) {
final String action = intent.getAction();
if (Log.LOGV) Log.v("AlarmInitReceiver" + action);
final PendingResult result = goAsync();
final WakeLock wl = AlarmAlertWakeLock.createPartialWakeLock(context);
... |
Inversion-Mutation | megadiff | "@Override public void run() {
// Remove the snooze alarm after a boot.
if (action.equals(Intent.ACTION_BOOT_COMPLETED)) {
Alarms.saveSnoozeAlert(context, Alarms.INVALID_ALARM_ID, -1);
Alarms.disableExpiredAlarms(context);
}
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "run" | "@Override public void run() {
// Remove the snooze alarm after a boot.
if (action.equals(Intent.ACTION_BOOT_COMPLETED)) {
Alarms.saveSnoozeAlert(context, Alarms.INVALID_ALARM_ID, -1);
}
<MASK>Alarms.disableExpiredAlarms(context... |
Inversion-Mutation | megadiff | "private void checkCollition() {
try {
itemCollition();
tileCollition();
iObjectCollition();
creatureCollition();
checkFalling();
} catch (ArrayIndexOutOfBoundsException e) {
new Sound().play("resources/sfx/kangaroo_death.WAV", false);
restartLevel();
}
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "checkCollition" | "private void checkCollition() {
try {
<MASK>creatureCollition();</MASK>
itemCollition();
tileCollition();
iObjectCollition();
checkFalling();
} catch (ArrayIndexOutOfBoundsException e) {
new Sound().play("resources/sfx/kangaroo_death.WAV", false);
restartLevel();
}
}" |
Inversion-Mutation | megadiff | "public String getHelp() {
StringBuffer help = new StringBuffer();
help.append("---"); //$NON-NLS-1$
help.append("Configurator Commands"); //$NON-NLS-1$
help.append("---"); //$NON-NLS-1$
help.append(NEW_LINE);
help.append("\tconfapply [<config URL>] - Applies a configuration"); //$NON-NLS-1$
help.... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "getHelp" | "public String getHelp() {
StringBuffer help = new StringBuffer();
<MASK>help.append(NEW_LINE);</MASK>
help.append("---"); //$NON-NLS-1$
help.append("Configurator Commands"); //$NON-NLS-1$
help.append("---"); //$NON-NLS-1$
<MASK>help.append(NEW_LINE);</MASK>
help.append("\tconfapply [<config URL>] ... |
Inversion-Mutation | megadiff | "@Override
protected void mergeRatio(Ratio old, Ratio ratio) {
old.setTotalCount(old.getTotalCount() + ratio.getTotalCount());
old.setTotalTime(old.getTotalTime() + ratio.getTotalTime());
if (old.getMin() == 0) {
old.setMin(ratio.getMin());
}
if (ratio.getMin() < old.getMin()) {
old.setMin(rat... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "mergeRatio" | "@Override
protected void mergeRatio(Ratio old, Ratio ratio) {
<MASK>old.setUrl(ratio.getUrl());</MASK>
old.setTotalCount(old.getTotalCount() + ratio.getTotalCount());
old.setTotalTime(old.getTotalTime() + ratio.getTotalTime());
if (old.getMin() == 0) {
old.setMin(ratio.getMin());
}
if (ratio.ge... |
Inversion-Mutation | megadiff | "public void setPosition(double lat, double lon, int zoom){
MapController mc = map.getController();
GeoPoint p = new GeoPoint((int)(lat*1E6), (int)(lon*1E6));
logOverlay.add(p);
mc.setCenter(p);
mc.setZoom(zoom);
this.myOverlay.getMyLocation();
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "setPosition" | "public void setPosition(double lat, double lon, int zoom){
MapController mc = map.getController();
GeoPoint p = new GeoPoint((int)(lat*1E6), (int)(lon*1E6));
mc.setCenter(p);
mc.setZoom(zoom);
this.myOverlay.getMyLocation();
<MASK>logOverlay.add(p);</MASK>
}" |
Inversion-Mutation | megadiff | "private Element upload(Element params, ServiceContext context)
throws Exception {
String uploadDir = context.getUploadDir();
Element uploadResult = null;
// Upload RDF file
String fname = null;
String url = null;
File rdfFile = null;
Element param = params.getChild(Params.FNAME);
if (pa... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "upload" | "private Element upload(Element params, ServiceContext context)
throws Exception {
String uploadDir = context.getUploadDir();
Element uploadResult = null;
// Upload RDF file
String fname = null;
String url = null;
File rdfFile = null;
Element param = params.getChild(Params.FNAME);
if (pa... |
Inversion-Mutation | megadiff | "public List getUserGroupIDs(String playerName)
{
if (config.webappSecondaryGroupStorageMethod.toLowerCase().startsWith("sin"))
{
return getUserGroupIDsSingleColumn(playerName);
}
else if (config.webappSecondaryGroupStorageMethod.toLowerCase().startsWith("jun"))
{
return getUserGroupIDsJuncti... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "getUserGroupIDs" | "public List getUserGroupIDs(String playerName)
{
if (config.webappSecondaryGroupStorageMethod.toLowerCase().startsWith("sin"))
{
return getUserGroupIDsSingleColumn(playerName);
}
else if (config.webappSecondaryGroupStorageMethod.toLowerCase().startsWith("jun"))
{
return getUserGroupIDsJuncti... |
Inversion-Mutation | megadiff | "public SessionImpl(String workspaceName, ConversationState userState, ExoContainer container)
throws RepositoryException
{
this.workspaceName = workspaceName;
this.container = container;
this.live = true;
this.id = System.currentTimeMillis() + "_" + SEQUENCE.incrementAndGet();
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "SessionImpl" | "public SessionImpl(String workspaceName, ConversationState userState, ExoContainer container)
throws RepositoryException
{
this.workspaceName = workspaceName;
this.container = container;
this.live = true;
this.id = System.currentTimeMillis() + "_" + SEQUENCE.incrementAndGet();
... |
Inversion-Mutation | megadiff | "public void dispose() {
if (scp == null) {
// already disposed!
return;
}
if (Activator.DEBUG) {
Activator.log.debug("ComponentInstanceImpl.dispose(): disposing instance of component " + scp.name, null); //$NON-NLS-1$
}
if (!scp.isComponentFactory() && scp.serviceComponent.factory != null) {... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "dispose" | "public void dispose() {
if (scp == null) {
// already disposed!
return;
}
if (Activator.DEBUG) {
Activator.log.debug("ComponentInstanceImpl.dispose(): disposing instance of component " + scp.name, null); //$NON-NLS-1$
}
if (!scp.isComponentFactory() && scp.serviceComponent.factory != null) {... |
Inversion-Mutation | megadiff | "public HttpAccess getHttpAccess()
{
return new HttpAccess()
{
public void handleAccess(HttpServletRequest req, HttpServletResponse res, Reference ref,
Collection copyrightAcceptedRefs) throws EntityPermissionException, EntityNotDefinedException,
EntityAccessOverloadException, EntityCopyrightExc... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "getHttpAccess" | "public HttpAccess getHttpAccess()
{
return new HttpAccess()
{
public void handleAccess(HttpServletRequest req, HttpServletResponse res, Reference ref,
Collection copyrightAcceptedRefs) throws EntityPermissionException, EntityNotDefinedException,
EntityAccessOverloadException, EntityCopyrightExc... |
Inversion-Mutation | megadiff | "public void handleAccess(HttpServletRequest req, HttpServletResponse res, Reference ref,
Collection copyrightAcceptedRefs) throws EntityPermissionException, EntityNotDefinedException,
EntityAccessOverloadException, EntityCopyrightException
{
try
{
Site site = (Site) ref.getEntity();
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "handleAccess" | "public void handleAccess(HttpServletRequest req, HttpServletResponse res, Reference ref,
Collection copyrightAcceptedRefs) throws EntityPermissionException, EntityNotDefinedException,
EntityAccessOverloadException, EntityCopyrightException
{
try
{
Site site = (Site) ref.getEntity();
... |
Inversion-Mutation | megadiff | "public void drawAll(){
// Runtime.getRuntime().exec("cls");
System.out.print(String.format("%c8", escCode));
// int row = 0;
// int column =0;
// System.out.print(String.format("%c[%d;%df", escCode, row, column));
for(int i = 0; i < size; i++){
for(int j = 0; j < size; j++){
if(grid[... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "drawAll" | "public void drawAll(){
// Runtime.getRuntime().exec("cls");
System.out.print(String.format("%c8", escCode));
// int row = 0;
// int column =0;
// System.out.print(String.format("%c[%d;%df", escCode, row, column));
<MASK>System.out.println();</MASK>
for(int i = 0; i < size; i++){
for(int j... |
Inversion-Mutation | megadiff | "public void run() {
int priority = Thread.currentThread().getPriority();
Thread.currentThread().setPriority(Thread.MAX_PRIORITY);
try {
stop = true;
while(stop) {
try {
// attempt masking at this rate
Thread.current... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "run" | "public void run() {
int priority = Thread.currentThread().getPriority();
Thread.currentThread().setPriority(Thread.MAX_PRIORITY);
try {
stop = true;
while(stop) {
<MASK>System.out.print("\010" + echochar);</MASK>
try {
... |
Inversion-Mutation | megadiff | "public void test() throws Exception {
testTransaction(false);
testCreateDrop();
if (config.memory) {
return;
}
testMultiThreaded();
testStreamLob();
test(false, "VARCHAR");
test(false, "CLOB");
testPerformance(false);
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "test" | "public void test() throws Exception {
testTransaction(false);
<MASK>testTransaction(true);</MASK>
testCreateDrop();
if (config.memory) {
return;
}
testMultiThreaded();
testStreamLob();
test(false, "VARCHAR");
test(false, "CLO... |
Inversion-Mutation | megadiff | "@Override
public synchronized void onSuccess(BaseClientPutter state, ObjectContainer container) {
try {
synchronized(mMessageManager) {
WoTOwnMessage m = (WoTOwnMessage)mMessageManager.getOwnMessage(mMessageIDs.get(state));
m.markAsInserted(state.getURI());
mMessageManager.addMessageToMessageLi... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "onSuccess" | "@Override
public synchronized void onSuccess(BaseClientPutter state, ObjectContainer container) {
try {
synchronized(mMessageManager) {
WoTOwnMessage m = (WoTOwnMessage)mMessageManager.getOwnMessage(mMessageIDs.get(state));
m.markAsInserted(state.getURI());
mMessageManager.addMessageToMessageLi... |
Inversion-Mutation | megadiff | "@Test
public void testPidParameter02() throws Exception {
String containerXml = this.theContainerXml;
Document containerDoc = EscidocAbstractTest.getDocument(containerXml);
String containerId = getObjidValue(containerDoc);
DateTime lmd = getLastModificationDateValue2(contain... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "testPidParameter02" | "@Test
public void testPidParameter02() throws Exception {
<MASK>String pidToRegister = "hdl:testPrefix/" + containerId;</MASK>
String containerXml = this.theContainerXml;
Document containerDoc = EscidocAbstractTest.getDocument(containerXml);
String containerId = getObjidValue... |
Inversion-Mutation | megadiff | "@Override
public void processHttpResponse(Context context) {
ContentResolver resolver = context.getContentResolver();
// Delete old logins
resolver.delete(RedditContract.Login.CONTENT_URI, null, null);
RedditLoginResponse response = JsonDeserializer.deserialize(resu... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "processHttpResponse" | "@Override
public void processHttpResponse(Context context) {
ContentResolver resolver = context.getContentResolver();
// Delete old logins
resolver.delete(RedditContract.Login.CONTENT_URI, null, null);
RedditLoginResponse response = JsonDeserializer.deserialize(resu... |
Inversion-Mutation | megadiff | "public String formatDateDiff(long date) {
Calendar now = new GregorianCalendar();
Calendar c = new GregorianCalendar();
c.setTimeInMillis(date);
return formatDateDiff(now, c);
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "formatDateDiff" | "public String formatDateDiff(long date) {
Calendar c = new GregorianCalendar();
c.setTimeInMillis(date);
<MASK>Calendar now = new GregorianCalendar();</MASK>
return formatDateDiff(now, c);
}" |
Inversion-Mutation | megadiff | "private void handleCommand(Command cmd) {
switch (cmd) {
case LEFT:
this.client.write("se;");
this.client.write("ga;");
break;
case RIGHT:
this.client.write("a;");
this.client.write("ba;");
break;
case UP:
this.client.write("la;");
this.client.write("pr;");
break;
cas... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "handleCommand" | "private void handleCommand(Command cmd) {
switch (cmd) {
case LEFT:
this.client.write("se;");
this.client.write("ga;");
break;
case RIGHT:
this.client.write("a;");
this.client.write("ba;");
break;
case UP:
this.client.write("la;");
this.client.write("pr;");
break;
cas... |
Inversion-Mutation | megadiff | "@SuppressWarnings("unchecked")
private void executeRewrite() {
BufferedReader reader = null;
PrintStream output = null;
try {
try {
reader = new BufferedReader(new FileReader(input));
output = new PrintStream(new File(destDir, input.getName()));
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "executeRewrite" | "@SuppressWarnings("unchecked")
private void executeRewrite() {
BufferedReader reader = null;
PrintStream output = null;
try {
try {
reader = new BufferedReader(new FileReader(input));
output = new PrintStream(new File(destDir, input.getName()));
... |
Inversion-Mutation | megadiff | "@Override
protected void configure() {
DynamicMap.mapOf(binder(), PROJECT_KIND);
DynamicMap.mapOf(binder(), DASHBOARD_KIND);
get(PROJECT_KIND).to(GetProject.class);
get(PROJECT_KIND, "description").to(GetDescription.class);
put(PROJECT_KIND, "description").to(SetDescription.class);
d... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "configure" | "@Override
protected void configure() {
DynamicMap.mapOf(binder(), PROJECT_KIND);
DynamicMap.mapOf(binder(), DASHBOARD_KIND);
get(PROJECT_KIND).to(GetProject.class);
get(PROJECT_KIND, "description").to(GetDescription.class);
put(PROJECT_KIND, "description").to(SetDescription.class);
d... |
Inversion-Mutation | megadiff | "private List<SearchItem> getAllItems(FindByProduct productRequest, FindItemsByProductResponse response, List<SearchItem> items) {
List<SearchItem> totalItems = new ArrayList<SearchItem>();
PaginationOutput outPage = response.getPaginationOutput();
totalItems.addAll(items);
if (items... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "getAllItems" | "private List<SearchItem> getAllItems(FindByProduct productRequest, FindItemsByProductResponse response, List<SearchItem> items) {
List<SearchItem> totalItems = new ArrayList<SearchItem>();
PaginationOutput outPage = response.getPaginationOutput();
if (items.size() < outPage.getTotalEntries(... |
Inversion-Mutation | megadiff | "protected void mergeInDefaultConfigs(ConfigObject config,
List<Class<?>> defaultConfigClasses, GroovyClassLoader classLoader) {
ConfigSlurper configSlurper = new ConfigSlurper(Environment
.getCurrent().getName());
configSlurper.setClassLoader(classLoader);
for ... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "mergeInDefaultConfigs" | "protected void mergeInDefaultConfigs(ConfigObject config,
List<Class<?>> defaultConfigClasses, GroovyClassLoader classLoader) {
ConfigSlurper configSlurper = new ConfigSlurper(Environment
.getCurrent().getName());
<MASK>configSlurper.setBinding(config);</MASK>
c... |
Inversion-Mutation | megadiff | "public void shutdown(ShutdownListener listener) {
synchronized (monitor) {
if (this.listener != null) {
throw new ElasticSearchIllegalStateException("Shutdown was already called on this thread pool");
}
if (isTerminated()) {
listener.onT... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "shutdown" | "public void shutdown(ShutdownListener listener) {
synchronized (monitor) {
if (this.listener != null) {
throw new ElasticSearchIllegalStateException("Shutdown was already called on this thread pool");
}
if (isTerminated()) {
listener.onT... |
Inversion-Mutation | megadiff | "public void addSeamRuntime(String name, String version, String seamHome) {
log.info("Adding Seam Runtime: " + name +
"\nVersion: " + version +
"\nHome: " + seamHome);
SWTBot wiz = open.preferenceOpen(ActionItem.Preference.JBossToolsWebSeam.LABEL);
SWTBotTable tbRuntimeEnvironments = bot.table();
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "addSeamRuntime" | "public void addSeamRuntime(String name, String version, String seamHome) {
log.info("Adding Seam Runtime: " + name +
"\nVersion: " + version +
"\nHome: " + seamHome);
SWTBot wiz = open.preferenceOpen(ActionItem.Preference.JBossToolsWebSeam.LABEL);
SWTBotTable tbRuntimeEnvironments = bot.table();
... |
Inversion-Mutation | megadiff | "private void initialize(Concept concept, ConceptName conceptName, Locale locale) {
if (concept != null) {
conceptId = concept.getConceptId();
ConceptName conceptShortName = concept.getShortNameInLocale(locale);
name = shortName = description = "";
if (conceptName != null) {
conceptNameId = con... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "initialize" | "private void initialize(Concept concept, ConceptName conceptName, Locale locale) {
if (concept != null) {
conceptId = concept.getConceptId();
<MASK>conceptNameId = conceptName.getConceptNameId();</MASK>
ConceptName conceptShortName = concept.getShortNameInLocale(locale);
name = shortName = descripti... |
Inversion-Mutation | megadiff | "@Override
public void setDisplayName(String name)
{
Preconditions.checkArgument( name.length() <= 16, "Display name cannot be longer than 16 characters" );
bungee.getTabListHandler().onDisconnect( this );
displayName=name;
bungee.getTabListHandler().onConnect( this );
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "setDisplayName" | "@Override
public void setDisplayName(String name)
{
Preconditions.checkArgument( name.length() <= 16, "Display name cannot be longer than 16 characters" );
<MASK>displayName=name;</MASK>
bungee.getTabListHandler().onDisconnect( this );
bungee.getTabListHandler().onConnect... |
Inversion-Mutation | megadiff | "public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
Player send;
if(!(sender instanceof Player)){
sender.sendMessage(title + ChatColor.RED + "Player context is required!");
return true;
}
send = (Player) sender;
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "onCommand" | "public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
Player send;
if(!(sender instanceof Player)){
sender.sendMessage(title + ChatColor.RED + "Player context is required!");
return true;
}
send = (Player) sender;
... |
Inversion-Mutation | megadiff | "private void cameraZoomOut(State toState, boolean animated) {
final Resources res = getResources();
final boolean toAllApps = (toState == State.ALL_APPS);
final int duration = toAllApps ?
res.getInteger(R.integer.config_allAppsZoomInTime) :
res.getInteger(... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "cameraZoomOut" | "private void cameraZoomOut(State toState, boolean animated) {
final Resources res = getResources();
final boolean toAllApps = (toState == State.ALL_APPS);
final int duration = toAllApps ?
res.getInteger(R.integer.config_allAppsZoomInTime) :
res.getInteger(... |
Inversion-Mutation | megadiff | "protected void disconnected ( final Throwable reason )
{
IoSession session;
boolean doClose = false;
synchronized ( this )
{
// disconnect the messenger here
this.messenger.disconnected ();
session = this.session;
if ( s... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "disconnected" | "protected void disconnected ( final Throwable reason )
{
IoSession session;
boolean doClose = false;
synchronized ( this )
{
// disconnect the messenger here
this.messenger.disconnected ();
session = this.session;
if ( s... |
Inversion-Mutation | megadiff | "public static void main(String args[]) {
if (args.length != 4) {
System.out.println("error: Wrong number of arguments.");
System.out.println("usage: java diff <sents.ans> <sents.out> <model_file> <report>");
System.exit(1);
}
// take in params
Strin... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "main" | "public static void main(String args[]) {
if (args.length != 4) {
System.out.println("error: Wrong number of arguments.");
System.out.println("usage: java diff <sents.ans> <sents.out> <model_file> <report>");
System.exit(1);
}
// take in params
Strin... |
Inversion-Mutation | megadiff | "public VisualizadorHorarioObjeto(java.awt.Window parent, boolean modal, Object objetoQueVerHorario, int modo, Profesor profesorAAsignar) {
super(parent);
initComponents();
this.modo = modo;
int i, j;
this.horasOcupadasDelProfe = new ArrayList();
this.horasDispDelPr... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "VisualizadorHorarioObjeto" | "public VisualizadorHorarioObjeto(java.awt.Window parent, boolean modal, Object objetoQueVerHorario, int modo, Profesor profesorAAsignar) {
super(parent);
initComponents();
this.modo = modo;
int i, j;
this.horasOcupadasDelProfe = new ArrayList();
this.horasDispDelPr... |
Inversion-Mutation | megadiff | "public Scene(SceneElement e) {
this(e.toString());
String title = e.getName();
this.setTitle(title);
int height = e.getHeight() + e.getY();
int width = e.getWidth() + e.getX();
this.setSize(width, height);
this.add(e);
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "Scene" | "public Scene(SceneElement e) {
this(e.toString());
<MASK>this.setTitle(title);</MASK>
String title = e.getName();
int height = e.getHeight() + e.getY();
int width = e.getWidth() + e.getX();
this.setSize(width, height);
this.add(e);
}" |
Inversion-Mutation | megadiff | "@Override
public void regionAdded(RegionEvent evt) {
if (!isActive()) return;
if (evt.getRegion()!=null) {
IRegion region = evt.getRegion();
region.addROIListener(this);
region.getROI().setPlot(true);
// set the Region isActive flag
region.setActive(true);
}
if (viewer!=null) viewer.... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "regionAdded" | "@Override
public void regionAdded(RegionEvent evt) {
if (!isActive()) return;
<MASK>if (viewer!=null) viewer.refresh();</MASK>
if (evt.getRegion()!=null) {
IRegion region = evt.getRegion();
region.addROIListener(this);
region.getROI().setPlot(true);
// set the Region isActive flag
region... |
Inversion-Mutation | megadiff | "@Override public boolean equals(Object o){
if(!(o instanceof ValueString)) return false;
ValueString str = (ValueString)o;
if(_skips.isEmpty() && str._skips.isEmpty()){ // no skipped chars
if(str._length != _length)return false;
for(int i = 0; i < _length; ++i)
if(_buf[_off+i] !=... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "equals" | "@Override public boolean equals(Object o){
if(!(o instanceof ValueString)) return false;
ValueString str = (ValueString)o;
<MASK>if(str._length != _length)return false;</MASK>
if(_skips.isEmpty() && str._skips.isEmpty()){ // no skipped chars
for(int i = 0; i < _length; ++i)
if(_buf... |
Inversion-Mutation | megadiff | "public boolean hasSideEffects()
{
switch (type) {
case Token.EXPR_VOID:
case Token.COMMA:
if (last != null)
return last.hasSideEffects();
else
return true;
case Token.HOOK:
if (first == null ||
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "hasSideEffects" | "public boolean hasSideEffects()
{
switch (type) {
case Token.EXPR_VOID:
<MASK>case Token.EXPR_RESULT:</MASK>
case Token.COMMA:
if (last != null)
return last.hasSideEffects();
else
return true;
case T... |
Inversion-Mutation | megadiff | "protected static synchronized void initDriver(QueryServices services, String url) throws Exception {
if (driver == null) {
if (driverRefCount == 0) {
BaseTest.driver = new PhoenixTestDriver(services, url, TEST_PROPERTIES);
DriverManager.registerDriver(driver);
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "initDriver" | "protected static synchronized void initDriver(QueryServices services, String url) throws Exception {
if (driver == null) {
if (driverRefCount == 0) {
<MASK>driverRefCount++;</MASK>
BaseTest.driver = new PhoenixTestDriver(services, url, TEST_PROPERTIES);
... |
Inversion-Mutation | megadiff | "@Subscribe
public void constructMod(FMLConstructionEvent event)
{
try
{
ModClassLoader modClassLoader = event.getModClassLoader();
modClassLoader.addFile(source);
modClassLoader.clearNegativeCacheFor(candidate.getClassList());
Class<?> cla... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "constructMod" | "@Subscribe
public void constructMod(FMLConstructionEvent event)
{
try
{
ModClassLoader modClassLoader = event.getModClassLoader();
modClassLoader.addFile(source);
modClassLoader.clearNegativeCacheFor(candidate.getClassList());
Class<?> cla... |
Inversion-Mutation | megadiff | "private synchronized void init() {
if (isInit)
return;
isInit = true;
// Note: we mark the initial contact point as UP, because we have no prior
// notion of their state and no real way to know until we connect to them
// (since the no... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "init" | "private synchronized void init() {
if (isInit)
return;
// Note: we mark the initial contact point as UP, because we have no prior
// notion of their state and no real way to know until we connect to them
// (since the node status is not exposed by... |
Inversion-Mutation | megadiff | "@Test
public void testShutdownDuringReacquireDelay() throws Exception {
ServiceTriggers leaderTriggers = new ServiceTriggers();
ServiceTriggers triggers1 = new ServiceTriggers();
ServiceTriggers triggers2 = new ServiceTriggers();
LeaderService leader = leaderTriggers.listenTo(n... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "testShutdownDuringReacquireDelay" | "@Test
public void testShutdownDuringReacquireDelay() throws Exception {
ServiceTriggers leaderTriggers = new ServiceTriggers();
ServiceTriggers triggers1 = new ServiceTriggers();
ServiceTriggers triggers2 = new ServiceTriggers();
LeaderService leader = leaderTriggers.listenTo(n... |
Inversion-Mutation | megadiff | "protected void drawClock(Svg g, int clock, int position, HashMap<String, Color> colorScheme) {
Transform t = new Transform();
t.rotate(Math.toRadians(position*30));
int netX = 0;
int netY = 0;
int deltaX, deltaY;
if(clock < 9) {
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "drawClock" | "protected void drawClock(Svg g, int clock, int position, HashMap<String, Color> colorScheme) {
Transform t = new Transform();
int netX = 0;
int netY = 0;
int deltaX, deltaY;
if(clock < 9) {
deltaX = radius + gap;
deltaY... |
Inversion-Mutation | megadiff | "@Test
public void testShip() {
IPlayer p = new Player("test");
HashMap<String, ICell> map1 = new HashMap<String, ICell>();
map1.put(Cell.createKey(c1.getX(), c1.getY()), c1);
assertNull(c1.getShip());
Ship s1 = new Ship(p, map1);
c1.setShip(s1);
as... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "testShip" | "@Test
public void testShip() {
IPlayer p = new Player("test");
HashMap<String, ICell> map1 = new HashMap<String, ICell>();
map1.put(Cell.createKey(c1.getX(), c1.getY()), c1);
<MASK>Ship s1 = new Ship(p, map1);</MASK>
assertNull(c1.getShip());
c1.setShip(s1)... |
Inversion-Mutation | megadiff | "@Override
public boolean warpPlayerExecute(WarpSuitePlayer player, List<String> args, List<String> variables)
{
if(args.size() == 0)
{
return false;
}
if(!Permissions.WARP_SET.check(player))
{
return Util.invalidPermissions(player);
}
int allowedWarps = NumeralPermissions.COUNT... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "warpPlayerExecute" | "@Override
public boolean warpPlayerExecute(WarpSuitePlayer player, List<String> args, List<String> variables)
{
if(args.size() == 0)
{
return false;
}
if(!Permissions.WARP_SET.check(player))
{
return Util.invalidPermissions(player);
}
int allowedWarps = NumeralPermissions.COUNT... |
Inversion-Mutation | megadiff | "public Canvas compile(File file, OutputStream ostr, Properties props, CompilationEnvironment env)
throws CompilationError, IOException
{
mLogger.info("compiling " + file + "...");
CompilationErrorHandler errors = env.getErrorHandler();
env.setApplicationFile(file);
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "compile" | "public Canvas compile(File file, OutputStream ostr, Properties props, CompilationEnvironment env)
throws CompilationError, IOException
{
mLogger.info("compiling " + file + "...");
CompilationErrorHandler errors = env.getErrorHandler();
env.setApplicationFile(file);
... |
Inversion-Mutation | megadiff | "public Protocol findProtocol(String protocolName) {
Protocol protocol = null;
try {
if (knownProtocols.containsKey(protocolName)) {
protocol = (Protocol) knownProtocols.get(protocolName).newInstance();
} else {
Class protocolClass ... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "findProtocol" | "public Protocol findProtocol(String protocolName) {
Protocol protocol = null;
try {
if (knownProtocols.containsKey(protocolName)) {
protocol = (Protocol) knownProtocols.get(protocolName).newInstance();
} else {
Class protocolClass ... |
Inversion-Mutation | megadiff | "private void setupNavigationList() {
ArrayAdapter<String> navAdapter = new CustomArrayAdapter(mContext,
R.layout.people_navigation_item);
navAdapter.add(mContext.getString(R.string.contactsFavoritesLabel));
navAdapter.add(mContext.getString(R.string.contactsAllLabel));
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "setupNavigationList" | "private void setupNavigationList() {
ArrayAdapter<String> navAdapter = new CustomArrayAdapter(mContext,
R.layout.people_navigation_item);
<MASK>navAdapter.add(mContext.getString(R.string.contactsAllLabel));</MASK>
navAdapter.add(mContext.getString(R.string.contactsFavoritesL... |
Inversion-Mutation | megadiff | "public void testInstrumentClass() throws Exception {
assertEquals(6, MyClass.staticSix());
final MyClass c1 = new MyClass();
assertEquals(0, c1.getA());
m_recorderStubFactory.assertNoMoreCalls();
m_instrumenter.createInstrumentedProxy(null, m_recorder, MyClass.class);
m_recorderSt... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "testInstrumentClass" | "public void testInstrumentClass() throws Exception {
assertEquals(6, MyClass.staticSix());
final MyClass c1 = new MyClass();
assertEquals(0, c1.getA());
m_recorderStubFactory.assertNoMoreCalls();
m_instrumenter.createInstrumentedProxy(null, m_recorder, MyClass.class);
m_recorderSt... |
Inversion-Mutation | megadiff | "public void popRTFContext()
{
int previous=m_last_pushed_rtfdtm.pop();
if(null==m_rtfdtm_stack)
return;
if(m_which_rtfdtm==previous)
{
if(previous>=0) // guard against none-active
{
boolean isEmpty=((SAX2RTFDTM)(m_rtfdtm_stack.elementAt(previous))).popRewindMark();
}
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "popRTFContext" | "public void popRTFContext()
{
if(null==m_rtfdtm_stack)
return;
<MASK>int previous=m_last_pushed_rtfdtm.pop();</MASK>
if(m_which_rtfdtm==previous)
{
if(previous>=0) // guard against none-active
{
boolean isEmpty=((SAX2RTFDTM)(m_rtfdtm_stack.elementAt(previous))).popRewindMar... |
Inversion-Mutation | megadiff | "public TestSuiteState validateSaveState(ITestSuitePO ts) {
if (Plugin.getDefault().anyDirtyStar()) {
boolean isSaved = Plugin.getDefault().showSaveEditorDialog();
if (isSaved) {
SortedSet<ITestSuitePO> allTestSuites =
getAllTestSuites();
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "validateSaveState" | "public TestSuiteState validateSaveState(ITestSuitePO ts) {
if (Plugin.getDefault().anyDirtyStar()) {
boolean isSaved = Plugin.getDefault().showSaveEditorDialog();
if (isSaved) {
SortedSet<ITestSuitePO> allTestSuites =
getAllTestSuites();
... |
Inversion-Mutation | megadiff | "synchronized public void shutdown() {
_log.notice("shutting down");
Enumeration e = _providers.elements();
while (e.hasMoreElements()) {
Provider pr = (Provider) e.nextElement();
_log.info("stopping: " + pr);
pr.destroy();
}
_providers.clear();
_... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "shutdown" | "synchronized public void shutdown() {
_log.notice("shutting down");
Enumeration e = _providers.elements();
<MASK>_providers.clear();</MASK>
while (e.hasMoreElements()) {
Provider pr = (Provider) e.nextElement();
_log.info("stopping: " + pr);
pr.destroy();
... |
Inversion-Mutation | megadiff | "protected void fillManifest(boolean compatibilityManifest) {
generateManifestVersion();
generateHeaders();
generateClasspath();
generateActivator();
generatePluginClass();
generateProvidePackage();
generateRequireBundle();
generateLocalizationEntry();
generateEclipseHeaders();
if (compati... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "fillManifest" | "protected void fillManifest(boolean compatibilityManifest) {
generateManifestVersion();
generateHeaders();
generateClasspath();
generateActivator();
generatePluginClass();
generateProvidePackage();
generateRequireBundle();
generateLocalizationEntry();
if (compatibilityManifest) {
genera... |
Inversion-Mutation | megadiff | "public RentPropertiesManager(String propertiesName){
this.propertiesName = propertiesName;
propFile = new File(RentDirectoryManager.getPathInDir(propertiesName));
prop = new Properties();
logManager = new RentLogManager(Logger.getLogger("Minecraft"));
setupDefaults();
update();
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "RentPropertiesManager" | "public RentPropertiesManager(String propertiesName){
this.propertiesName = propertiesName;
propFile = new File(RentDirectoryManager.getPathInDir(propertiesName));
prop = new Properties();
logManager = new RentLogManager(Logger.getLogger("Minecraft"));
<MASK>update();</MASK>
setupDefaults();
}" |
Inversion-Mutation | megadiff | "private void restoreAudio() {
if (systemVolume != -1) {
Log.i(LOG_TAG, "Resetting volume to " + systemVolume);
audioManager.setStreamVolume(READING_AUDIO_STREAM, systemVolume, 0);
}
audioManager.setStreamSolo(READING_AUDIO_STREAM, false);
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "restoreAudio" | "private void restoreAudio() {
if (systemVolume != -1) {
Log.i(LOG_TAG, "Resetting volume to " + systemVolume);
audioManager.setStreamVolume(READING_AUDIO_STREAM, systemVolume, 0);
<MASK>audioManager.setStreamSolo(READING_AUDIO_STREAM, false);</MASK>
}
}" |
Inversion-Mutation | megadiff | "public void run(){
BufferedReader is;
try {
os = s.getOutputStream();
os.write(new String("Welcome!").getBytes());
is = new BufferedReader(new InputStreamReader(s.getInputStream()));
setupDone = true;
while (running){
if (!s.isConnected()){//Disconnect
running = false;
b... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "run" | "public void run(){
BufferedReader is;
try {
<MASK>os.write(new String("Welcome!").getBytes());</MASK>
os = s.getOutputStream();
is = new BufferedReader(new InputStreamReader(s.getInputStream()));
setupDone = true;
while (running){
if (!s.isConnected()){//Disconnect
running = fa... |
Inversion-Mutation | megadiff | "@Override
public boolean next() {
if (firstMatch) {
firstMatch = false;
ctx.goodPushEnv();
leftResult = left.next();
right.init();
return leftResult && right.next();
}
if (right.hasNext()) {
// first do the right.next because && would short cut it which leads to an infinite loop ... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "next" | "@Override
public boolean next() {
if (firstMatch) {
firstMatch = false;
ctx.goodPushEnv();
leftResult = left.next();
<MASK>right.init();</MASK>
return leftResult && right.next();
}
if (right.hasNext()) {
// first do the right.next because && would short cut it which leads to an i... |
Inversion-Mutation | megadiff | "protected void init() throws IOException {
securityMap = new HashMap<String, List<SecurityEntry>>();
Set<String> authNames = attrAdapter.getAuthorityUrls().keySet();
for (String authName : authNames) {
List<SecurityEntry> securityEntries = new ArrayList<SecurityEntry>();
InputStream in = getClass().g... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "init" | "protected void init() throws IOException {
securityMap = new HashMap<String, List<SecurityEntry>>();
<MASK>List<SecurityEntry> securityEntries = new ArrayList<SecurityEntry>();</MASK>
Set<String> authNames = attrAdapter.getAuthorityUrls().keySet();
for (String authName : authNames) {
InputStream in = ... |
Inversion-Mutation | megadiff | "protected void readFromXMLImpl(XMLStreamReader in) throws XMLStreamException {
final String id = in.getAttributeValue(null, "id");
if (id == null && getId().equals("NO_ID")){
throw new XMLStreamException("invalid <" + getXMLElementTagName() + "> tag : no id attribute found.");
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "readFromXMLImpl" | "protected void readFromXMLImpl(XMLStreamReader in) throws XMLStreamException {
final String id = in.getAttributeValue(null, "id");
if (id == null && getId().equals("NO_ID")){
throw new XMLStreamException("invalid <" + getXMLElementTagName() + "> tag : no id attribute found.");
... |
Inversion-Mutation | megadiff | "public void tick()
{
if(_mustUpdate)
{
_mustUpdate = false;
updatePowerLevels();
}
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "tick" | "public void tick()
{
if(_mustUpdate)
{
<MASK>updatePowerLevels();</MASK>
_mustUpdate = false;
}
}" |
Inversion-Mutation | megadiff | "public TalkingLine() {
condPar = new ArrayList<ConditionParser>();
consPar = new ArrayList<ConsequenceParser>();
condPar.add(new illarion.easynpc.parser.talk.conditions.State());
condPar.add(new illarion.easynpc.parser.talk.conditions.Skill());
condPar.add(new illarion.ea... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "TalkingLine" | "public TalkingLine() {
condPar = new ArrayList<ConditionParser>();
consPar = new ArrayList<ConsequenceParser>();
condPar.add(new illarion.easynpc.parser.talk.conditions.State());
condPar.add(new illarion.easynpc.parser.talk.conditions.Skill());
condPar.add(new illarion.ea... |
Inversion-Mutation | megadiff | "public void decode(String batchFile) {
BatchItem batchItem;
int count = 0;
try {
recognizer.allocate();
setBatchFile(batchFile);
batchManager.start();
logger.info("BatchDecoder: decoding files in "
+ batchManager.getF... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "decode" | "public void decode(String batchFile) {
BatchItem batchItem;
int count = 0;
try {
recognizer.allocate();
setBatchFile(batchFile);
batchManager.start();
logger.info("BatchDecoder: decoding files in "
+ batchManager.getF... |
Inversion-Mutation | megadiff | "public void testAll() {
runTests(new TestDescriptor[] {
new TestDescriptor(TEST1, "", 1, new ConstructorCallsOverridableMethodRule()),
new TestDescriptor(TEST2, "", 1, new ConstructorCallsOverridableMethodRule()),
new TestDescriptor(TEST3, "", 1, new ConstructorCallsOverrida... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "testAll" | "public void testAll() {
runTests(new TestDescriptor[] {
new TestDescriptor(TEST1, "", 1, new ConstructorCallsOverridableMethodRule()),
new TestDescriptor(TEST2, "", 1, new ConstructorCallsOverridableMethodRule()),
new TestDescriptor(TEST3, "", 1, new ConstructorCallsOverrida... |
Inversion-Mutation | megadiff | "public final boolean cancel( boolean mayInterruptIfRunning ) {
boolean did = false;
synchronized(this) { // Install the answer under lock
if( !isCancelled() ) {
did = true; // Did cancel (was not cancelled already)
_target.taskRemove(_tasknum);
_target = n... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "cancel" | "public final boolean cancel( boolean mayInterruptIfRunning ) {
boolean did = false;
synchronized(this) { // Install the answer under lock
if( !isCancelled() ) {
did = true; // Did cancel (was not cancelled already)
_target = null; // Flag as canceled
... |
Inversion-Mutation | megadiff | "public boolean generate(World world, int x, int y, int z)
{
int orientation = 0;
if (this.getSchematicPath()!=null)
{
//Get the correct filters
GatewayBlockFilter filter = new GatewayBlockFilter();
DungeonSchematic schematic = this.getSchematicToBuild(world, x, y, z);
//apply filter... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "generate" | "public boolean generate(World world, int x, int y, int z)
{
int orientation = 0;
if (this.getSchematicPath()!=null)
{
//Get the correct filters
GatewayBlockFilter filter = new GatewayBlockFilter();
DungeonSchematic schematic = this.getSchematicToBuild(world, x, y, z);
//apply filter... |
Inversion-Mutation | megadiff | "public void destroy()
{
mCache.destroy();
// close all listeners
final Iterator it = mListeners.iterator();
while (it.hasNext()) {
final AuditListener listener = (AuditListener) it.next();
final OutputStream os = listener.getOutputStream();
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "destroy" | "public void destroy()
{
mCache.destroy();
// close all listeners
final Iterator it = mListeners.iterator();
while (it.hasNext()) {
final AuditListener listener = (AuditListener) it.next();
final OutputStream os = listener.getOutputStream();
... |
Inversion-Mutation | megadiff | "private void followTradeRoute(Unit unit) {
Stop stop = unit.getCurrentStop();
if (stop == null) {
return;
}
Location location = unit.getLocation();
if (location instanceof Tile) {
location = ((Tile) location).getColony();
}
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "followTradeRoute" | "private void followTradeRoute(Unit unit) {
Stop stop = unit.getCurrentStop();
if (stop == null) {
return;
}
<MASK>// load cargo that should be on board</MASK>
Location location = unit.getLocation();
if (location instanceof Tile) {
... |
Inversion-Mutation | megadiff | "public static void writeExcelSheet(PafExcelInput input, List<PafExcelRow> paceRowList) throws PafException {
if ( input == null ) {
throw new IllegalArgumentException("Pace Excel Input cannot be null");
} else if ( input.getFullWorkbookName() == null && input.getWorkbook() == null ) {
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "writeExcelSheet" | "public static void writeExcelSheet(PafExcelInput input, List<PafExcelRow> paceRowList) throws PafException {
if ( input == null ) {
throw new IllegalArgumentException("Pace Excel Input cannot be null");
} else if ( input.getFullWorkbookName() == null && input.getWorkbook() == null ) {
... |
Inversion-Mutation | megadiff | "public Application(){
this.gameOver = false;
this.gh = new GameHelper();
this.dotComField = new DotComField[7][7];
this.oppenedFields = new boolean[7][7];
for(int i = 0; i < 7; i++){
for(int j = 0; j < 7; j++){
this.dotComField[i][j]=null;
this.oppenedFields[i][j]=false;
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "Application" | "public Application(){
this.gameOver = false;
this.gh = new GameHelper();
this.dotComField = new DotComField[7][7];
this.oppenedFields = new boolean[7][7];
for(int i = 0; i < 7; i++){
for(int j = 0; j < 7; j++){
this.dotComField[i][j]=null;
this.oppenedFields[i][j]=false;
... |
Inversion-Mutation | megadiff | "@Override
public void run()
{
tx = indexService.beginTx();
lastCommit = System.currentTimeMillis();
try
{
while ( run || !queue.isEmpty() )
{
QueueElement qe = queue.poll();
try
{
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "run" | "@Override
public void run()
{
tx = indexService.beginTx();
lastCommit = System.currentTimeMillis();
try
{
while ( run || !queue.isEmpty() )
{
QueueElement qe = queue.poll();
try
{
... |
Inversion-Mutation | megadiff | "private void write(Graph linkset) throws IOException {
for (Link link : linkset) {
if (link.hasReferenceSource()) {
if (link.hasReferenceTarget()) {
link(link.getSourceAsReference(), link.getTypeRef(), link
.getTargetAsReference()... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "write" | "private void write(Graph linkset) throws IOException {
for (Link link : linkset) {
if (link.hasReferenceSource()) {
if (link.hasReferenceTarget()) {
link(link.getSourceAsReference(), link.getTypeRef(), link
.getTargetAsReference()... |
Inversion-Mutation | megadiff | "@Override protected void onCreate(Bundle savedInstanceState) {
requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
super.onCreate(savedInstanceState);
setProgressBarIndeterminate(true);
setContentView(R.layout.activity_song_list);
setTitle(R.string.sn_songs_activity_title);
sear... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "onCreate" | "@Override protected void onCreate(Bundle savedInstanceState) {
<MASK>super.onCreate(savedInstanceState);</MASK>
requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
setProgressBarIndeterminate(true);
setContentView(R.layout.activity_song_list);
setTitle(R.string.sn_songs_activity_title)... |
Inversion-Mutation | megadiff | "Wad(WadParse w, MainFrame m, String filename) {
wp = w;
wr = w.wr;
mf = m;
mf.msg("writing wad to "+filename);
try {
f = new RandomAccessFile(filename,"rw");
f.writeBytes("PWAD");
writeInt(wr.hexen ? 7 : 6); // numentries
writeInt(12); // dir offset
int tsiz... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "Wad" | "Wad(WadParse w, MainFrame m, String filename) {
wp = w;
wr = w.wr;
mf = m;
mf.msg("writing wad to "+filename);
try {
f = new RandomAccessFile(filename,"rw");
f.writeBytes("PWAD");
writeInt(wr.hexen ? 7 : 6); // numentries
writeInt(12); // dir offset
int tsiz... |
Inversion-Mutation | megadiff | "void toggleWifi() {
if(PENDINGWIFITOGGLE)
return;
PENDINGWIFITOGGLE=true;
cleanupPosts();
tempLock(CONNECTWAIT);
hMainWrapper(WIFI_OFF);
hMain.removeMessages(WIFI_ON);
hMain.sendEmptyMessageDelayed(WIFI_ON, LOOPWAIT);
PENDINGSCAN=true;
startScan();
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "toggleWifi" | "void toggleWifi() {
if(PENDINGWIFITOGGLE)
return;
PENDINGWIFITOGGLE=true;
tempLock(CONNECTWAIT);
hMainWrapper(WIFI_OFF);
hMain.removeMessages(WIFI_ON);
<MASK>cleanupPosts();</MASK>
hMain.sendEmptyMessageDelayed(WIFI_ON, LOOPWAIT);
PENDINGSCAN=true;
startScan();
}" |
Inversion-Mutation | megadiff | "public List<String> createCommandLine() {
List<String> cmdline = new ArrayList<String>(50);
cmdline.add(javaExecutable);
cmdline.add("-XX:-ReduceInitialCardMarks");
cmdline.add("-XX:+HeapDumpOnOutOfMemoryError");
cmdline.add("-Djava.library.path=" + java_library_path);
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "createCommandLine" | "public List<String> createCommandLine() {
List<String> cmdline = new ArrayList<String>(50);
cmdline.add(javaExecutable);
cmdline.add("-XX:-ReduceInitialCardMarks");
cmdline.add("-XX:+HeapDumpOnOutOfMemoryError");
<MASK>if (rmi_host_name != null)</MASK>
cmdline.add(... |
Inversion-Mutation | megadiff | "@Override
public void processTick(double dt)
{
if(hit)
{
return;
}
Vector3 targetPos = target != null ? target.getPosition() : staticTarget;
Vector3 dir = targetPos.subtract(getPosition()).normalized();
setOrientation(Math... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "processTick" | "@Override
public void processTick(double dt)
{
if(hit)
{
return;
}
Vector3 targetPos = target != null ? target.getPosition() : staticTarget;
Vector3 dir = targetPos.subtract(getPosition()).normalized();
setOrientation(Math... |
Inversion-Mutation | megadiff | "protected MockServletContext createMockServletContext(Woko woko) {
MockServletContext mockServletContext = new CloseableMockServletContext(contextName);
mockServletContext.setAttribute(Woko.CTX_KEY, woko);
mockServletContext.addFilter(StripesFilter.class, "StripesFilter", getParamsMap());
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "createMockServletContext" | "protected MockServletContext createMockServletContext(Woko woko) {
MockServletContext mockServletContext = new CloseableMockServletContext(contextName);
mockServletContext.addFilter(StripesFilter.class, "StripesFilter", getParamsMap());
mockServletContext.setServlet(DispatcherServlet.class,... |
Inversion-Mutation | megadiff | "public InputVolumeControlButton(Call call,
boolean fullScreen,
boolean selected)
{
this( call,
ImageLoader.MICROPHONE,
ImageLoader.MUTE_BUTTON,
fullScreen,
true... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "InputVolumeControlButton" | "public InputVolumeControlButton(Call call,
boolean fullScreen,
boolean selected)
{
this( call,
ImageLoader.MICROPHONE,
ImageLoader.MUTE_BUTTON,
<MASK>true,</MASK>
... |
Inversion-Mutation | megadiff | "protected void doGet(HttpServletRequest request,
HttpServletResponse response) throws ServletException, IOException {
request.setCharacterEncoding("UTF-8");
response.setCharacterEncoding("UTF-8");
Connection c = null;
PreparedStatement stmt = null;
ResultSet rs = null;
String statement;
Strin... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "doGet" | "protected void doGet(HttpServletRequest request,
HttpServletResponse response) throws ServletException, IOException {
<MASK>response.setCharacterEncoding("UTF-8");</MASK>
request.setCharacterEncoding("UTF-8");
Connection c = null;
PreparedStatement stmt = null;
ResultSet rs = null;
String statem... |
Inversion-Mutation | megadiff | "public void resume(boolean fireNotification) throws DebugException {
if (!isSuspended()) {
return;
}
try {
setSuspended(false);
resumeThreads();
getVM().resume();
if (fireNotification) {
fireResumeEvent(DebugEvent.CLIENT_REQUEST);
}
} catch (VMDisconnectedException e) {
di... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "resume" | "public void resume(boolean fireNotification) throws DebugException {
if (!isSuspended()) {
return;
}
try {
setSuspended(false);
<MASK>getVM().resume();</MASK>
resumeThreads();
if (fireNotification) {
fireResumeEvent(DebugEvent.CLIENT_REQUEST);
}
} catch (VMDisconnectedExceptio... |
Inversion-Mutation | megadiff | "@Override
public void parseArgs(ScriptEntry scriptEntry) throws InvalidArgumentsException {
List<ScriptQueue> queues = new ArrayList<ScriptQueue>();
// Use current queue if none specified.
queues.add(ScriptQueue._getQueue(scriptEntry.getResidingQueue()));
for (String arg ... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "parseArgs" | "@Override
public void parseArgs(ScriptEntry scriptEntry) throws InvalidArgumentsException {
List<ScriptQueue> queues = new ArrayList<ScriptQueue>();
// Use current queue if none specified.
queues.add(ScriptQueue._getQueue(scriptEntry.getResidingQueue()));
for (String arg ... |
Inversion-Mutation | megadiff | "public Gui_StreamRipStar(Boolean openPreferences)
{
super("StreamRipStar");
setIconImage( windowIcon.getImage() );
controlStreams = new Control_Stream(this);
table = new Gui_TablePanel(controlStreams,this);
addWindowListener(this);
setDefaultCloseOperation( JFrame.DO_NOTHING_ON_CLOSE );
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "Gui_StreamRipStar" | "public Gui_StreamRipStar(Boolean openPreferences)
{
super("StreamRipStar");
setIconImage( windowIcon.getImage() );
controlStreams = new Control_Stream(this);
table = new Gui_TablePanel(controlStreams,this);
addWindowListener(this);
setDefaultCloseOperation( JFrame.DO_NOTHING_ON_CLOSE );
... |
Inversion-Mutation | megadiff | "@Override
public DropAction dragEnter(Component component, Manifest dragContent,
int supportedDropActions, DropAction userDropAction) {
DropAction action = null;
if (dragContent.containsFileList()
&& DropAction.COPY.isSelected(supportedDropActions)) {
action = DropAction.COPY;
} else if (dragC... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "dragEnter" | "@Override
public DropAction dragEnter(Component component, Manifest dragContent,
int supportedDropActions, DropAction userDropAction) {
<MASK>designTree = (TreeView) component;</MASK>
DropAction action = null;
if (dragContent.containsFileList()
&& DropAction.COPY.isSelected(supportedDropActions)) {... |
Inversion-Mutation | megadiff | "private void processLoginAttempt(final Connection con,
final String username, final String password) {
LOGGER.trace("Processing login attempt");
// TODO Exceeded maximum login attempts
HibernateUtils.beginTransaction();
Account account = accountDAO.findByUsername(userna... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "processLoginAttempt" | "private void processLoginAttempt(final Connection con,
final String username, final String password) {
LOGGER.trace("Processing login attempt");
// TODO Exceeded maximum login attempts
HibernateUtils.beginTransaction();
Account account = accountDAO.findByUsername(userna... |
Inversion-Mutation | megadiff | "public BoardView(Parent parent) {
super(parent);
firstTime = System.currentTimeMillis();
setAutoCellSize();
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "BoardView" | "public BoardView(Parent parent) {
<MASK>firstTime = System.currentTimeMillis();</MASK>
super(parent);
setAutoCellSize();
}" |
Inversion-Mutation | megadiff | "public static String viewPost(String username, String boardName,
String regionName, int postNum) {
Connection dbconn = DBManager.getConnection();
String bname = boardName.trim().toLowerCase();
if (bname.equals("freeforall")) {
Boolean postExists = postExists("freeforall", null, postNum);
if (pos... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "viewPost" | "public static String viewPost(String username, String boardName,
String regionName, int postNum) {
Connection dbconn = DBManager.getConnection();
String bname = boardName.trim().toLowerCase();
<MASK>String rname = regionName.trim().toLowerCase();</MASK>
if (bname.equals("freeforall")) {
Boolean po... |
Inversion-Mutation | megadiff | "public void shutdown() {
dataNode.shutdown();
nameNode.shutdown();
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "shutdown" | "public void shutdown() {
<MASK>nameNode.shutdown();</MASK>
dataNode.shutdown();
}" |
Inversion-Mutation | megadiff | "public WorkerImpl(final Config config, final Collection<String> queues,
final Map<String, ? extends Class<?>> jobTypes) {
if (config == null) {
throw new IllegalArgumentException("config must not be null");
}
checkQueues(queues);
checkJobTypes(jobTypes);
... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "WorkerImpl" | "public WorkerImpl(final Config config, final Collection<String> queues,
final Map<String, ? extends Class<?>> jobTypes) {
if (config == null) {
throw new IllegalArgumentException("config must not be null");
}
checkQueues(queues);
checkJobTypes(jobTypes);
... |
Inversion-Mutation | megadiff | "public static Test suite( )
{
TestSuite suite = new TestSuite( "Test for org.eclipse.birt.data.engine" );
/* in package: org.eclipse.birt.data.engine.aggregation */
suite.addTestSuite( org.eclipse.birt.data.engine.aggregation.FinanceTest.class );
suite.addTestSuite( org.eclipse.birt.data.engine.aggre... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "suite" | "public static Test suite( )
{
TestSuite suite = new TestSuite( "Test for org.eclipse.birt.data.engine" );
/* in package: org.eclipse.birt.data.engine.aggregation */
suite.addTestSuite( org.eclipse.birt.data.engine.aggregation.FinanceTest.class );
suite.addTestSuite( org.eclipse.birt.data.engine.aggre... |
Inversion-Mutation | megadiff | "private void addDoLoadMethod(StringComposite sc) {
sc.add("protected void doLoad(" + INPUT_STREAM + " inputStream, " + MAP + "<?,?> options) throws " + IO_EXCEPTION + " {");
sc.add(STRING + " encoding = null;");
sc.add(INPUT_STREAM + " actualInputStream = inputStream;");
sc.add(OBJECT + "... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "addDoLoadMethod" | "private void addDoLoadMethod(StringComposite sc) {
sc.add("protected void doLoad(" + INPUT_STREAM + " inputStream, " + MAP + "<?,?> options) throws " + IO_EXCEPTION + " {");
sc.add(STRING + " encoding = null;");
sc.add(INPUT_STREAM + " actualInputStream = inputStream;");
sc.add(OBJECT + "... |
Inversion-Mutation | megadiff | "@Override
@Before
public void setUp() throws Exception {
System.setProperty("vfs.sftp.sshdir", new File("./tests/sshd-config/").getAbsolutePath());
super.setUp();
ConnectionDescription dst = new ConnectionDescription(new URI("sftp://127.0.0.1:2222/"));
dst.setParameter("bufferStrategy", "");
dst.set... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "setUp" | "@Override
@Before
public void setUp() throws Exception {
super.setUp();
ConnectionDescription dst = new ConnectionDescription(new URI("sftp://127.0.0.1:2222/"));
dst.setParameter("bufferStrategy", "");
dst.setParameter("username", "SampleUser");
dst.setSecretParameter("password", "SampleUser");
... |
Inversion-Mutation | megadiff | "public void popupDismissed(boolean topPopupOnly) {
initializePopup();
// if the 2nd level popup gets dismissed
if (mPopupStatus == POPUP_SECOND_LEVEL) {
mPopupStatus = POPUP_FIRST_LEVEL;
if (topPopupOnly) mModule.showPopup(mPopup);
}
}" | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "popupDismissed" | "public void popupDismissed(boolean topPopupOnly) {
// if the 2nd level popup gets dismissed
if (mPopupStatus == POPUP_SECOND_LEVEL) {
<MASK>initializePopup();</MASK>
mPopupStatus = POPUP_FIRST_LEVEL;
if (topPopupOnly) mModule.showPopup(mPopup);
}
... |
Inversion-Mutation | megadiff | "@Override
public synchronized ProcessWrapper launchTranscode(
DLNAResource dlna,
DLNAMediaInfo media,
OutputParams params
) throws IOException {
params.minBufferSize = params.minFileSize;
params.secondread_minsize = 100000;
RendererConfiguration renderer = params.mediaRenderer;
String filename... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "launchTranscode" | "@Override
public synchronized ProcessWrapper launchTranscode(
DLNAResource dlna,
DLNAMediaInfo media,
OutputParams params
) throws IOException {
params.minBufferSize = params.minFileSize;
params.secondread_minsize = 100000;
RendererConfiguration renderer = params.mediaRenderer;
setAudioAndSub... |
Inversion-Mutation | megadiff | "@Override
public void actionPerformed(ActionEvent e) {
// TODO: abfragen, welche Bits gesetzt sind und ensprechend handeln
player = (Player)level.getPlayer();
Vector2d position = player.getPosition();
if(!(direction.getX() == 0 && direction.getY() == 0)){
lastDirection = direction;
}
directio... | You are a Java Developer and you want to perform "Inversion-Mutation" by changing order of statementsfor provided "actionPerformed" | "@Override
public void actionPerformed(ActionEvent e) {
// TODO: abfragen, welche Bits gesetzt sind und ensprechend handeln
player = (Player)level.getPlayer();
Vector2d position = player.getPosition();
if(!(direction.getX() == 0 && direction.getY() == 0)){
lastDirection = direction;
<MASK>}</MASK... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.