buggy_function stringlengths 1 391k | fixed_function stringlengths 0 392k |
|---|---|
public static void issueStopCommandToMonitor(
String commKey, String host, int monitorPort)
throws IOException, JettyMonitorException
{
Socket socket = null;
try
{
socket = new Socket(InetAddress.getByName(host), monitorPort);
OutputStream out = socket.getOutputStream();
out.write((commKey + "\r\... | public static void issueStopCommandToMonitor(
String commKey, String host, int monitorPort)
throws IOException, JettyMonitorException
{
Socket socket = null;
try
{
socket = new Socket(InetAddress.getByName(host), monitorPort);
OutputStream out = socket.getOutputStream();
out.write((commKey + "\r\... |
public void handleEvent (Event event) {
if (event.widget == cancel) {
shell.close ();
}
if (helperAppLauncher != null) {
helperAppLauncher.Cancel ();
helperAppLauncher.Release ();
}
shell = null;
helperAppLauncher = null;
}
};
shell = new Shell (SWT.DIALOG_TRIM);
String msg = Compat... | public void handleEvent (Event event) {
if (event.widget == cancel) {
shell.close ();
}
if (helperAppLauncher != null) {
helperAppLauncher.Cancel ();
helperAppLauncher.Release ();
}
shell = null;
helperAppLauncher = null;
}
};
shell = new Shell (SWT.DIALOG_TRIM);
String msg = Compat... |
public void handleEvent (Event event) {
if (event.widget == cancel) {
shell.close ();
}
if (cancelable != null) {
int rc = cancelable.Cancel (XPCOM.NS_BINDING_ABORTED);
if (rc != XPCOM.NS_OK) Mozilla.error (rc);
}
shell = null;
cancelable = null;
}
};
shell = new Shell (SWT.DIALOG_TR... | public void handleEvent (Event event) {
if (event.widget == cancel) {
shell.close ();
}
if (cancelable != null) {
int rc = cancelable.Cancel (XPCOM.NS_BINDING_ABORTED);
if (rc != XPCOM.NS_OK) Mozilla.error (rc);
}
shell = null;
cancelable = null;
}
};
shell = new Shell (SWT.DIALOG_TR... |
public HeaderSectionPage_10(final PageParameters parameters)
{
add(new HeaderSectionPanel_2("panel"));
}
| public HeaderSectionPage_10(final PageParameters parameters)
{
add(new HeaderSectionPanel_3("panel"));
}
|
private void handleRegisteredServiceEvent(
ServiceReference serviceReference, Collection contexts) {
// This checkes to see if the serviceReference has any remote interfaces declared via
// osgi.remote.interfaces
Object remoteInterfaces = serviceReference.getProperty(ServiceConstants.OSGI_REMOTE_INTERFACES_KE... | private void handleRegisteredServiceEvent(
ServiceReference serviceReference, Collection contexts) {
// This checkes to see if the serviceReference has any remote interfaces declared via
// osgi.remote.interfaces
Object remoteInterfaces = serviceReference.getProperty(ServiceConstants.OSGI_REMOTE_INTERFACES);
... |
public void endTest(Test test) {
// Fix for bug #5637 - if a junit.extensions.TestSetup is
// used and throws an exception during setUp then startTest
// would never have been called
if (!testStarts.containsKey(test)) {
startTest(test);
}
Element currentT... | public void endTest(Test test) {
// Fix for bug #5637 - if a junit.extensions.TestSetup is
// used and throws an exception during setUp then startTest
// would never have been called
if (!testStarts.containsKey(test)) {
startTest(test);
}
Element currentT... |
private void processStandardError()
{
final InputStream input = m_process.getInputStream();
copy( input, m_error );
}
| private void processStandardError()
{
final InputStream input = m_process.getErrorStream();
copy( input, m_error );
}
|
protected void setUp() throws Exception {
super.setUp();
aRightState = new AjState(null);
oldConfig = new AjBuildConfig();
newConfig = new AjBuildConfig();
List cp = new ArrayList();
cp.add("adir");
cp.add("ajar.jar");
oldConfig.setClasspath(cp);
... | protected void setUp() throws Exception {
super.setUp();
aRightState = new AjState(null);
oldConfig = new AjBuildConfig();
newConfig = new AjBuildConfig();
List cp = new ArrayList();
cp.add("adir");
cp.add("ajar.jar");
oldConfig.setClasspath(cp);
... |
public StatGraphVisualizer() {
super();
model = new ObjectTableModel(COLUMNS,
SamplingStatCalculator.class,
new Functor[] {
new Functor("getLabel"), //$NON-NLS-1$
new Functor("getCount"), //$NON-NLS... | public StatGraphVisualizer() {
super();
model = new ObjectTableModel(COLUMNS,
SamplingStatCalculator.class,
new Functor[] {
new Functor("getLabel"), //$NON-NLS-1$
new Functor("getCount"), //$NON-NLS... |
public TableVisualizer() {
super();
model = new ObjectTableModel(COLUMNS,
Sample.class, // The object used for each row
new Functor[] {
new Functor("getCount"), // $NON-NLS-1$
new Functor("getStartTimeFormatted", // $NON-NLS-1$... | public TableVisualizer() {
super();
model = new ObjectTableModel(COLUMNS,
Sample.class, // The object used for each row
new Functor[] {
new Functor("getCount"), // $NON-NLS-1$
new Functor("getStartTimeFormatted", // $NON-NLS-1$... |
public void renderOnEventJavascript(String target, String event, String javascript)
{
if (!closed)
{
List<Object> token = Arrays.asList(new Object[] { "javascript-event", target, event,
javascript });
if (wasRendered(token) == false)
{
renderJavascriptReference(WicketEventReference.INSTANCE);
... | public void renderOnEventJavascript(String target, String event, String javascript)
{
if (!closed)
{
List<Object> token = Arrays.asList(new Object[] { "javascript-event", target, event,
javascript });
if (wasRendered(token) == false)
{
renderJavascriptReference(WicketEventReference.INSTANCE);
... |
private void validate(MyAjaxSelfUpdatingTimerBehavior timer, boolean inBodyOnLoad)
{
String document = tester.getServletResponse().getDocument();
String updateScript = timer.getUpdateScript();
if (inBodyOnLoad)
{
String bodyOnLoadUpdateScript = "Wicket.Event.add(window, \"load\", function() { " +
upd... | private void validate(MyAjaxSelfUpdatingTimerBehavior timer, boolean inBodyOnLoad)
{
String document = tester.getServletResponse().getDocument();
String updateScript = timer.getUpdateScript();
if (inBodyOnLoad)
{
String bodyOnLoadUpdateScript = "Wicket.Event.add(window, \"load\", function(event) { " +
... |
void write(File file) throws IOException;
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache Licens... | void write(File file) throws IOException;
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache Licens... |
public void addSelectionListener(SelectionListener listener) {
checkWidget();
if (listener == null) error (SWT.ERROR_NULL_ARGUMENT);
TypedListener typedListener = new TypedListener(listener);
addListener(SWT.Selection,typedListener);
addListener(SWT.DefaultSelection,typedListener);
}
static int checkStyle (int sty... | public void addSelectionListener(SelectionListener listener) {
checkWidget();
if (listener == null) error (SWT.ERROR_NULL_ARGUMENT);
TypedListener typedListener = new TypedListener(listener);
addListener(SWT.Selection,typedListener);
addListener(SWT.DefaultSelection,typedListener);
}
static int checkStyle (int sty... |
public String getString(final String key, final Component component, final IModel model,
final Locale locale, final String style, final String defaultValue)
throws MissingResourceException
{
return null;
}
| public String getString(final String key, final Component component, final IModel model,
final Locale locale, final String style, final String defaultValue)
throws MissingResourceException
{
return getString(key, component, model, defaultValue);
}
|
public class ElementState
/*
* The Apache Software License, Version 1.1
*
*
* Copyright (c) 1999 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
*... | public class ElementState
/*
* The Apache Software License, Version 1.1
*
*
* Copyright (c) 1999 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
*... |
public void setSelection (int value) {
checkWidget ();
OS.SendMessage (handle, OS.TBM_SETPOS, 1, value);
}
int widgetStyle () {
int bits = super.widgetStyle () | OS.WS_TABSTOP | OS.TBS_BOTH | OS.TBS_AUTOTICKS;
if ((style & SWT.HORIZONTAL) != 0) return bits | OS.TBS_HORZ;
return bits | OS.TBS_VERT;
}
| public void setSelection (int value) {
checkWidget ();
OS.SendMessage (handle, OS.TBM_SETPOS, 1, value);
}
int widgetStyle () {
int bits = super.widgetStyle () | OS.WS_TABSTOP | OS.TBS_BOTH | OS.TBS_AUTOTICKS;
if ((style & SWT.HORIZONTAL) != 0) return bits | OS.TBS_HORZ | OS.TBS_DOWNISLEFT;
return bits | OS.TBS_V... |
public void remove (int [] indices) {
checkWidget ();
if (indices == null) error (SWT.ERROR_NULL_ARGUMENT);
if (indices.length == 0) return;
int [] newIndices = new int [indices.length];
System.arraycopy (indices, 0, newIndices, 0, indices.length);
sort (newIndices);
int start = newIndices [newIndices.length - 1... | public void remove (int [] indices) {
checkWidget ();
if (indices == null) error (SWT.ERROR_NULL_ARGUMENT);
if (indices.length == 0) return;
int [] newIndices = new int [indices.length];
System.arraycopy (indices, 0, newIndices, 0, indices.length);
sort (newIndices);
int start = newIndices [newIndices.length - 1... |
public void attlistDecl(QName elementDecl, QName attributeDecl,
int attType, boolean attList, String enumString,
int attDefaultType,
int attDefaultValue) throws Exception
{
if (fDeclHandler != null || DEBUG_CALLBACKS) {
... | public void attlistDecl(QName elementDecl, QName attributeDecl,
int attType, boolean attList, String enumString,
int attDefaultType,
int attDefaultValue) throws Exception
{
if (fDeclHandler != null || DEBUG_CALLBACKS) {
... |
public String toString() {
StringBuffer strRet = new StringBuffer(fLeaf.toString());
if (fPosition >= 0) {
strRet.append
(
" (Pos:"
+ new Integer(fPosition).toString()
+ ")"
);
}
return strRet.toStrin... | public String toString() {
StringBuffer strRet = new StringBuffer(fLeaf.toString());
if (fPosition >= 0) {
strRet.append
(
" (Pos:"
+ Integer.toString(fPosition)
+ ")"
);
}
return strRet.toString();
... |
public DBIdentifier loadIdentifierFromDB(DBDictionary dbdict, Connection conn) {
if( isLogical() || getTable() == null)
return DBIdentifier.NULL;
DBIdentifier retVal = DBIdentifier.NULL;
try{
Schema schema = getTable().getSchema();
ForeignKey[] fks = dbdic... | public DBIdentifier loadIdentifierFromDB(DBDictionary dbdict, Connection conn) {
if( isLogical() || getTable() == null)
return DBIdentifier.NULL;
DBIdentifier retVal = DBIdentifier.NULL;
try{
Schema schema = getTable().getSchema();
ForeignKey[] fks = dbdic... |
public void setAlpha (int alpha) {
checkWidget ();
alpha &= 0xFF;
OS.SetWindowAlpha (shellHandle, alpha / 255f);
}
int setBounds (int x, int y, int width, int height, boolean move, boolean resize, boolean events) {
if (fullScreen) setFullScreen (false);
Rect rect = new Rect ();
if (!move) {
OS.GetWindowBounds ... | public void setAlpha (int alpha) {
checkWidget ();
alpha &= 0xFF;
OS.SetWindowAlpha (shellHandle, alpha / 255f);
}
int setBounds (int x, int y, int width, int height, boolean move, boolean resize, boolean events) {
if (fullScreen) setFullScreen (false);
Rect rect = new Rect ();
if (!move) {
OS.GetWindowBounds ... |
public void removeDisposeListener (DisposeListener listener) {
checkWidget();
if (listener == null) error (SWT.ERROR_NULL_ARGUMENT);
if (eventTable == null) return;
eventTable.unhook (SWT.Dispose, listener);
}
boolean sendDragEvent (int x, int y) {
Event event = new Event ();
event.x = x;
event.y = y;
postEven... | public void removeDisposeListener (DisposeListener listener) {
checkWidget();
if (listener == null) error (SWT.ERROR_NULL_ARGUMENT);
if (eventTable == null) return;
eventTable.unhook (SWT.Dispose, listener);
}
boolean sendDragEvent (int x, int y) {
Event event = new Event ();
event.x = x;
event.y = y;
postEven... |
public AssertionResult getResult(SampleResult inResponse) {
log.debug("HTMLAssertions.getResult() called");
// no error as default
AssertionResult result = new AssertionResult();
if (inResponse.getResponseData() == null) {
return result.setResultForNull();
}
result.setFailure(false);
// create par... | public AssertionResult getResult(SampleResult inResponse) {
log.debug("HTMLAssertions.getResult() called");
// no error as default
AssertionResult result = new AssertionResult();
if (inResponse.getResponseData().length == 0) {
return result.setResultForNull();
}
result.setFailure(false);
// create... |
public AssertionResult getResult(SampleResult response) {
AssertionResult result = new AssertionResult();
result.setFailure(false);
byte[] resultData = response.getResponseData();
if (resultData == null) {
result.setError(false);
result.setFailure(true);
result.setFailureMessage("Response was null")... | public AssertionResult getResult(SampleResult response) {
AssertionResult result = new AssertionResult();
result.setFailure(false);
byte[] resultData = response.getResponseData();
if (resultData.length == 0) {
result.setError(false);
result.setFailure(true);
result.setFailureMessage("Response was nu... |
public AssertionResult getResult(SampleResult response) {
AssertionResult result = new AssertionResult();
// Note: initialised with error = failure = false
byte data[] = response.getResponseData();
if (data == null || data.length == 0) {
return result.setResultForNull();
}
String resultData = new Strin... | public AssertionResult getResult(SampleResult response) {
AssertionResult result = new AssertionResult();
// Note: initialised with error = failure = false
byte data[] = response.getResponseData();
if (data.length == 0) {
return result.setResultForNull();
}
String resultData = new String(getResultBody(... |
public void process() {
JMeterContext jmctx = JMeterContextService.getContext();
SampleResult prev = jmctx.getPreviousResult();
if (prev == null || prev.getResponseData() == null) {
return;
}
JMeterVariables vars = jmctx.getVariables();
try {
// Add variables fo... | public void process() {
JMeterContext jmctx = JMeterContextService.getContext();
SampleResult prev = jmctx.getPreviousResult();
if (prev == null || prev.getResponseData().length == 0) {
return;
}
JMeterVariables vars = jmctx.getVariables();
try {
// Add variable... |
public synchronized String execute(SampleResult previousResult, Sampler currentSampler)
throws InvalidVariableException {
String valueIndex = "", defaultValue = "", between = "";
String name = "";
Pattern searchPattern;
Object[] tmplt;
try {
searchPattern = patternCache.getPattern(((CompoundVariable) v... | public synchronized String execute(SampleResult previousResult, Sampler currentSampler)
throws InvalidVariableException {
String valueIndex = "", defaultValue = "", between = "";
String name = "";
Pattern searchPattern;
Object[] tmplt;
try {
searchPattern = patternCache.getPattern(((CompoundVariable) v... |
public void onComponentTag(Component component, ComponentTag tag)
{
tag.put("id", component.getPageRelativePath());
tag.put("onfocus", getFocusTrackingHandler(component));
super.onComponentTag(component, tag);
}
});
}
| public void onComponentTag(Component component, ComponentTag tag)
{
tag.put("id", component.getMarkupId());
tag.put("onfocus", getFocusTrackingHandler(component));
super.onComponentTag(component, tag);
}
});
}
|
private Vector loaderPackages = new Vector();
/**
* Create a classloader for the given project using the classpath given.
*
* @param project the project to ehich this classloader is to belong.
* @param classpath the classpath to use to load the classes. This
* is co... | private Vector loaderPackages = new Vector();
/**
* Create a classloader for the given project using the classpath given.
*
* @param project the project to ehich this classloader is to belong.
* @param classpath the classpath to use to load the classes. This
* is co... |
public void execute() throws BuildException {
if ("javadoc2".equals(taskType)) {
log("!! javadoc2 is deprecated. Use javadoc instead. !!");
}
if (sourcePath == null) {
String msg = "sourcePath attribute must be set!";
throw new BuildException(msg);
... | public void execute() throws BuildException {
if ("javadoc2".equals(taskType)) {
log("!! javadoc2 is deprecated. Use javadoc instead. !!");
}
if (sourcePath == null) {
String msg = "sourcePath attribute must be set!";
throw new BuildException(msg);
... |
public AppendingStringBuffer filter(AppendingStringBuffer responseBuffer)
{
int headIndex = responseBuffer.indexOf("<head>");
int bodyIndex = responseBuffer.indexOf("</body>");
int ajaxStart = responseBuffer.indexOf("<ajax-response>");
int ajaxEnd = responseBuffer.indexOf("</ajax-response>");
long timeTaken... | public AppendingStringBuffer filter(AppendingStringBuffer responseBuffer)
{
int headIndex = responseBuffer.indexOf("<head>");
int bodyIndex = responseBuffer.indexOf("</body>");
int ajaxStart = responseBuffer.indexOf("<ajax-response>");
int ajaxEnd = responseBuffer.indexOf("</ajax-response>");
long timeTaken... |
public AppendingStringBuffer filter(AppendingStringBuffer responseBuffer)
{
int headIndex = responseBuffer.indexOf("<head>");
int bodyIndex = responseBuffer.indexOf("</body>");
long timeTaken = System.currentTimeMillis() - RequestCycle.get().getStartTime();
if (headIndex != -1 && bodyIndex != -1)
{
Map<S... | public AppendingStringBuffer filter(AppendingStringBuffer responseBuffer)
{
int headIndex = responseBuffer.indexOf("<head>");
int bodyIndex = responseBuffer.indexOf("</body>");
long timeTaken = System.currentTimeMillis() - RequestCycle.get().getStartTime();
if (headIndex != -1 && bodyIndex != -1)
{
Map<S... |
public AppendingStringBuffer filter(AppendingStringBuffer responseBuffer)
{
int index = responseBuffer.indexOf("<head>");
long timeTaken = System.currentTimeMillis() - RequestCycle.get().getStartTime();
if (index != -1)
{
AppendingStringBuffer script = new AppendingStringBuffer(75);
script.append("\n");... | public AppendingStringBuffer filter(AppendingStringBuffer responseBuffer)
{
int index = responseBuffer.indexOf("<head>");
long timeTaken = System.currentTimeMillis() - RequestCycle.get().getStartTime();
if (index != -1)
{
AppendingStringBuffer script = new AppendingStringBuffer(75);
script.append("\n");... |
protected ClientInfo newClientInfo()
{
if (getApplication().getRequestCycleSettings().getGatherExtendedBrowserInfo())
{
Session session = getSession();
if (session.getMetaData(BROWSER_WAS_POLLED_KEY) == null)
{
// we haven't done the redirect yet; record that we will be
// doing that now and redi... | protected ClientInfo newClientInfo()
{
if (getApplication().getRequestCycleSettings().getGatherExtendedBrowserInfo())
{
Session session = getSession();
if (session.getMetaData(BROWSER_WAS_POLLED_KEY) == null)
{
// we haven't done the redirect yet; record that we will be
// doing that now and redi... |
public void deselectAll () {
checkWidget ();
TVITEM tvItem = new TVITEM ();
tvItem.mask = OS.TVIF_STATE;
tvItem.stateMask = OS.TVIS_SELECTED;
if ((style & SWT.SINGLE) != 0) {
int hItem = OS.SendMessage (handle, OS.TVM_GETNEXTITEM, OS.TVGN_CARET, 0);
if (hItem != 0) {
tvItem.hItem = hItem;
OS.SendMessage ... | public void deselectAll () {
checkWidget ();
TVITEM tvItem = new TVITEM ();
tvItem.mask = OS.TVIF_STATE;
tvItem.stateMask = OS.TVIS_SELECTED;
if ((style & SWT.SINGLE) != 0) {
int hItem = OS.SendMessage (handle, OS.TVM_GETNEXTITEM, OS.TVGN_CARET, 0);
if (hItem != 0) {
tvItem.hItem = hItem;
OS.SendMessage ... |
public void run() {
String from = ((fromName == null) ? "<nobody>" : fromName);
MessageDialog.openInformation(Display.getCurrent()
.getActiveShell(), "ECF Roster Size Message from "
+ from,
"For Group '"+groupName+"' active="+activeSize+" and total="+totalSize);
}
});
}
| public void run() {
String from = ((fromName == null) ? "<nobody>" : fromName);
MessageDialog.openInformation(Display.getCurrent()
.getActiveShell(), "ECF Roster Size Message from "
+ from,
from+"'s '"+groupName+"' group has "+activeSize+" active and "+totalSize+" total group members");
... |
public void setHeaderVisible (boolean show) {
checkWidget ();
short [] height = new short [1];
OS.GetDataBrowserListViewHeaderBtnHeight (handle, height);
if ((height [0] != 0) != show) {
OS.SetDataBrowserListViewHeaderBtnHeight (handle, (short) (show ? headerHeight : 0));
resetVisibleRegion (handle);
}
}
| public void setHeaderVisible (boolean show) {
checkWidget ();
short [] height = new short [1];
OS.GetDataBrowserListViewHeaderBtnHeight (handle, height);
if ((height [0] != 0) != show) {
OS.SetDataBrowserListViewHeaderBtnHeight (handle, (short) (show ? headerHeight : 0));
invalidateVisibleRegion (handle);
}
}
|
public void setHeaderVisible (boolean show) {
checkWidget ();
short [] height = new short [1];
OS.GetDataBrowserListViewHeaderBtnHeight (handle, height);
if ((height [0] != 0) != show) {
OS.SetDataBrowserListViewHeaderBtnHeight (handle, (short) (show ? headerHeight : 0));
//resetVisibleRegion (handle);
}
}
vo... | public void setHeaderVisible (boolean show) {
checkWidget ();
short [] height = new short [1];
OS.GetDataBrowserListViewHeaderBtnHeight (handle, height);
if ((height [0] != 0) != show) {
OS.SetDataBrowserListViewHeaderBtnHeight (handle, (short) (show ? headerHeight : 0));
invalidateVisibleRegion (handle);
}
}
... |
protected void registerResource( final String name,
final String classname,
final URL url )
throws AntException, RegistryException
{
if( null == classname )
{
try { m_engine.getTskDeployer().deployTa... | protected void registerResource( final String name,
final String classname,
final URL url )
throws AntException, RegistryException
{
if( null == classname )
{
try { m_tskDeployer.deployTasklet( name,... |
public AbstractSQLServerDictionary() {
reservedWordSet.addAll(Arrays.asList(new String[]{ "FILE", "INDEX" }));
systemTableSet.add("DTPROPERTIES");
validationSQL = "SELECT GETDATE()";
rangePosition = RANGE_POST_DISTINCT;
supportsDeferredConstraints = false;
supportsSe... | public AbstractSQLServerDictionary() {
reservedWordSet.addAll(Arrays.asList(new String[]{ "FILE", "INDEX", "RULE" }));
systemTableSet.add("DTPROPERTIES");
validationSQL = "SELECT GETDATE()";
rangePosition = RANGE_POST_DISTINCT;
supportsDeferredConstraints = false;
su... |
private void binaryCat(ResourceCollection c) {
log("Binary concatenation of " + c.size()
+ " resources to " + destinationFile);
FileOutputStream out = null;
InputStream in = null;
try {
try {
out = new FileOutputStream(destinationFile, append);... | private void binaryCat(ResourceCollection c) {
log("Binary concatenation of " + c.size()
+ " resources to " + destinationFile);
FileOutputStream out = null;
InputStream in = null;
try {
try {
out = new FileOutputStream(destinationFile.getPath()... |
public MarkupElement nextTag() throws ParseException
{
// Get the next tag. If null, no more tags are available
final ComponentTag tag = (ComponentTag)getParent().nextTag();
if (tag == null)
{
return tag;
}
// A new handler is created for each markup file. Hence it is
// sufficient to "create" the c... | public MarkupElement nextTag() throws ParseException
{
// Get the next tag. If null, no more tags are available
final ComponentTag tag = (ComponentTag)getParent().nextTag();
if (tag == null)
{
return tag;
}
// A new handler is created for each markup file. Hence it is
// sufficient to "create" the c... |
public static ReferenceType createParameterizedType(
ResolvedType aBaseType,
UnresolvedType[] someTypeParameters,
World inAWorld
) {
ResolvedType baseType = aBaseType;
if (!aBaseType.isGenericType()) {
// try and find the generic type...
if (someTypeParameters != null && someTypeParameters.length>0) {... | public static ReferenceType createParameterizedType(
ResolvedType aBaseType,
UnresolvedType[] someTypeParameters,
World inAWorld
) {
ResolvedType baseType = aBaseType;
if (!aBaseType.isGenericType()) {
// try and find the generic type...
if (someTypeParameters != null && someTypeParameters.length>0) {... |
private static final String[] MENU_ADD_CONTROLLER = new String[] { MenuFactory.CONTROLLERS, MenuFactory.SAMPLERS,
MenuFactory.ASSERTIONS, MenuFactory.CONFIG_ELEMENTS, MenuFactory.TIMERS, MenuFactory.LISTENERS, MenuFactory.PRE_PROCESSORS,
MenuFactory.POST_PROCESSORS };
| private static final String[] MENU_ADD_CONTROLLER = new String[] { MenuFactory.CONTROLLERS, MenuFactory.SAMPLERS,
MenuFactory.CONFIG_ELEMENTS, MenuFactory.TIMERS, MenuFactory.LISTENERS, MenuFactory.PRE_PROCESSORS,
MenuFactory.POST_PROCESSORS };
|
public JPopupMenu createPopupMenu() {
JPopupMenu pop = new JPopupMenu();
pop.add(MenuFactory.makeMenus(new String[] { MenuFactory.CONTROLLERS, MenuFactory.LISTENERS,
MenuFactory.SAMPLERS, MenuFactory.ASSERTIONS,MenuFactory.TIMERS, MenuFactory.CONFIG_ELEMENTS, MenuFactory.PRE_PROCESSORS,
MenuFactory.POST_PR... | public JPopupMenu createPopupMenu() {
JPopupMenu pop = new JPopupMenu();
pop.add(MenuFactory.makeMenus(new String[] { MenuFactory.CONTROLLERS, MenuFactory.LISTENERS,
MenuFactory.SAMPLERS, MenuFactory.TIMERS, MenuFactory.CONFIG_ELEMENTS, MenuFactory.PRE_PROCESSORS,
MenuFactory.POST_PROCESSORS }, JMeterUtils... |
package org.apache.myrmidon;
/*
* Copyright (C) The Apache Software Foundation. All rights reserved.
*
* This software is published under the terms of the Apache Software License
* version 1.1, a copy of which has been included with this distribution in
* the LICENSE file.
*/
package org.apache.ant;
/**
* Abst... | package org.apache.myrmidon;
/*
* Copyright (C) The Apache Software Foundation. All rights reserved.
*
* This software is published under the terms of the Apache Software License
* version 1.1, a copy of which has been included with this distribution in
* the LICENSE file.
*/
package org.apache.myrmidon;
/**
*... |
import org.apache.myrmidon.AntException;
/*
* Copyright (C) The Apache Software Foundation. All rights reserved.
*
* This software is published under the terms of the Apache Software License
* version 1.1, a copy of which has been included with this distribution in
* the LICENSE file.
*/
package org.apache.myrmi... | import org.apache.myrmidon.AntException;
/*
* Copyright (C) The Apache Software Foundation. All rights reserved.
*
* This software is published under the terms of the Apache Software License
* version 1.1, a copy of which has been included with this distribution in
* the LICENSE file.
*/
package org.apache.myrmi... |
import org.apache.myrmidon.AntException;
/*
* Copyright (C) The Apache Software Foundation. All rights reserved.
*
* This software is published under the terms of the Apache Software License
* version 1.1, a copy of which has been included with this distribution in
* the LICENSE file.
*/
package org.apache.myrmi... | import org.apache.myrmidon.AntException;
/*
* Copyright (C) The Apache Software Foundation. All rights reserved.
*
* This software is published under the terms of the Apache Software License
* version 1.1, a copy of which has been included with this distribution in
* the LICENSE file.
*/
package org.apache.myrmi... |
import org.apache.myrmidon.AntException;
/*
* Copyright (C) The Apache Software Foundation. All rights reserved.
*
* This software is published under the terms of the Apache Software License
* version 1.1, a copy of which has been included with this distribution in
* the LICENSE file.
*/
package org.apache.myrmi... | import org.apache.myrmidon.AntException;
/*
* Copyright (C) The Apache Software Foundation. All rights reserved.
*
* This software is published under the terms of the Apache Software License
* version 1.1, a copy of which has been included with this distribution in
* the LICENSE file.
*/
package org.apache.myrmi... |
public final static void main( final String[] args )
throws Exception
{
try
{
//actually try to discover the install directory based on where
// the ant.jar is
final File installDirectory = findInstallDir();
System.setProperty( "ant.home", ... | public final static void main( final String[] args )
throws Exception
{
try
{
//actually try to discover the install directory based on where
// the ant.jar is
final File installDirectory = findInstallDir();
System.setProperty( "ant.home", ... |
private void setInputUrlFromResourceLocation() {
try {
ClassLoader cl = _conf.getClassResolverInstance()
.getClassLoader(getClass(), null);
List list = new ArrayList();
for (Enumeration e = cl.getResources(_inputResourceLocation);
e.hasMore... | private void setInputUrlFromResourceLocation() {
try {
ClassLoader cl = _conf.getClassResolverInstance()
.getClassLoader(getClass(), null);
List list = new ArrayList();
for (Enumeration e = cl.getResources(_inputResourceLocation);
e.hasMore... |
public void widgetSelected (SelectionEvent e) {
Button button = (Button)e.widget;
Point pt = button.getLocation();
pt = e.display.map(button, null, pt);
createSetGetDialog(pt.x, pt.y, methodNames);
}
});
}
}
/**
* Creates the "Control" widget children.
* Subclasses override this ... | public void widgetSelected (SelectionEvent e) {
Button button = (Button)e.widget;
Point pt = button.getLocation();
pt = e.display.map(button, null, pt);
createSetGetDialog(pt.x, pt.y, methodNames);
}
});
}
}
/**
* Creates the "Control" widget children.
* Subclasses override this ... |
public void wake () {
synchronized (Device.class) {
if (isDisposed ()) error (SWT.ERROR_DEVICE_DISPOSED);
if (thread == Thread.currentThread ()) return;
wakeThread ();
}
}
void wakeThread () {
NSObject object = new NSObject().alloc().init();
object.performSelectorOnMainThread(OS.sel_release, null, false);
}
... | public void wake () {
synchronized (Device.class) {
if (isDisposed ()) error (SWT.ERROR_DEVICE_DISPOSED);
if (thread == Thread.currentThread ()) return;
wakeThread ();
}
}
void wakeThread () {
NSObject object = new NSObject().alloc().init();
object.performSelectorOnMainThread(OS.sel_release, null, false);
}
... |
public void handleEvent(Event e) {
Button b = new Button(c, SWT.PUSH);
b.setText("Special "+index[0]);
index[0]++;
Control[] children = c.getChildren();
b.moveAbove(children[3]);
shell.layout(true);
}
});
shell.open ();
... | public void handleEvent(Event e) {
Button b = new Button(c, SWT.PUSH);
b.setText("Special "+index[0]);
index[0]++;
Control[] children = c.getChildren();
b.moveAbove(children[3]);
shell.layout(new Control[] {b});
}
});
shell... |
protected synchronized Vector getFilters() {
if (isReference()) {
return getRef().getFilters();
}
dieOnCircularReference();
//silly hack to avoid stack overflow...
if (!readingFiles) {
readingFiles = true;
final int size = filtersFiles.size... | protected synchronized Vector getFilters() {
if (isReference()) {
return getRef().getFilters();
}
dieOnCircularReference();
//silly hack to avoid stack overflow...
if (!readingFiles) {
readingFiles = true;
final int size = filtersFiles.size... |
public static boolean getPropDefault(String propName, boolean defaultVal) {
boolean ans;
try {
String strVal = appProperties.getProperty(propName, JOrphanUtils.booleanToString(defaultVal)).trim();
if (strVal.equalsIgnoreCase("true") || strVal.equalsIgnoreCase("t")) { // $NON-NLS-1$ // $NON-NLS-2$
ans = ... | public static boolean getPropDefault(String propName, boolean defaultVal) {
boolean ans;
try {
String strVal = appProperties.getProperty(propName, Boolean.toString(defaultVal)).trim();
if (strVal.equalsIgnoreCase("true") || strVal.equalsIgnoreCase("t")) { // $NON-NLS-1$ // $NON-NLS-2$
ans = true;
} e... |
public void addValue(String key, Object value)
{
if (value instanceof String[])
{
String[] values = (String[])value;
for (int i = 0; i < values.length; i++)
{
addValue(key, values[i]);
}
}
else if (value instanceof String)
{
addValue(key, (String)value);
}
else
{
throw new Illega... | public void addValue(String key, Object value)
{
if (value instanceof String[])
{
String[] values = (String[])value;
for (int i = 0; i < values.length; i++)
{
addValue(key, values[i]);
}
}
else if (value instanceof String)
{
addValue(key, (String)value);
}
else
{
addValue(key, va... |
public void execute() throws BuildException {
if (dir == null) {
throw new BuildException("dir attribute is required", location);
}
if (dir.isFile()) {
throw new BuildException("Unable to create directory as a file already exists with that name: " + dir.getAbsolutePa... | public void execute() throws BuildException {
if (dir == null) {
throw new BuildException("dir attribute is required", location);
}
if (dir.isFile()) {
throw new BuildException("Unable to create directory as a file already exists with that name: " + dir.getAbsolutePa... |
public void getLocalpathCommand(Commandline cmd) {
if (m_LocalPath == null) {
return;
} else {
// make sure m_LocalDir exists, create it if it doesn't
File dir = project.resolveFile(m_LocalPath);
if (!dir.exists()) {
boolean done = dir.... | public void getLocalpathCommand(Commandline cmd) {
if (m_LocalPath == null) {
return;
} else {
// make sure m_LocalDir exists, create it if it doesn't
File dir = project.resolveFile(m_LocalPath);
if (!dir.exists()) {
boolean done = dir.... |
public void test_getOffsetAtLocationLorg_eclipse_swt_graphics_Point() {
boolean exceptionThrown = false;
Point location;
final int XINSET = isBidi() ? 2 : 0;
assertTrue(":a:", text.getOffsetAtLocation(new Point(XINSET, 0)) == 0);
try {
text.getOffsetAtLocation(new Point(-1, 0));
}
catch (IllegalArgumentExcep... | public void test_getOffsetAtLocationLorg_eclipse_swt_graphics_Point() {
boolean exceptionThrown = false;
Point location;
final int XINSET = isBidi() ? 2 : 0;
assertTrue(":a:", text.getOffsetAtLocation(new Point(XINSET, 0)) == 0);
try {
text.getOffsetAtLocation(new Point(-1, 0));
}
catch (IllegalArgumentExcep... |
import org.apache.wicket.authroles.authorization.strategies.role.annotations.AuthorizeInstantiation;
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
... | import org.apache.wicket.authroles.authorization.strategies.role.annotations.AuthorizeInstantiation;
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
... |
public Object addingService(ServiceReference reference) {
System.out.println("IHello service proxy being added");
IHello hello = (IHello) context.getService(reference);
// Call it
hello.hello();
System.out.println("Called hello() on proxy successfully");
// Now get remote service reference and use async... | public Object addingService(ServiceReference reference) {
System.out.println("IHello service proxy being added");
IHello hello = (IHello) context.getService(reference);
// Call it
hello.hello();
System.out.println("Called hello() on proxy successfully");
// Now get remote service reference and use async... |
public IChat createChat(ID targetUser) throws ECFException {
// TODO Auto-generated method stub
return null;
}
} | public IChat createChat(ID targetUser, IIMMessageListener messageListener) throws ECFException {
// TODO Auto-generated method stub
return null;
}
} |
protected void onDetach()
{
if ((fileUpload != null) && forceCloseStreamsOnDetach())
{
fileUpload.closeStreams();
fileUpload = null;
if (getModel() != null)
{
setModelObject(null);
}
}
super.onDetach();
}
| protected void onDetach()
{
if ((fileUpload != null) && forceCloseStreamsOnDetach())
{
fileUpload.closeStreams();
fileUpload = null;
if (getModel() != null)
{
getModel().setObject(null);
}
}
super.onDetach();
}
|
private void writeServices(ZipOutputStream zOut) throws IOException {
Iterator serviceIterator;
Service service;
serviceIterator = serviceList.iterator();
while (serviceIterator.hasNext()) {
service = (Service) serviceIterator.next();
//stolen from writeManifes... | private void writeServices(ZipOutputStream zOut) throws IOException {
Iterator serviceIterator;
Service service;
serviceIterator = serviceList.iterator();
while (serviceIterator.hasNext()) {
service = (Service) serviceIterator.next();
//stolen from writeManifes... |
private IFormValidationDelegate validationDelegate =
new IFormValidationDelegate.DefaultFormValidationDelegate();
| private IFormValidationDelegate validationDelegate =
new DefaultFormValidationDelegate();
|
public void insert(String string) {
checkWidget();
if (string == null) {
SWT.error(SWT.ERROR_NULL_ARGUMENT);
}
Point sel = getSelectionRange();
replaceTextRange(sel.x, sel.y, string);
}
void insertBlockSelectionText(String text, int action) {
int firstLine = getLineIndex(blockYAnchor - getVerticalScrollOffset()... | public void insert(String string) {
checkWidget();
if (string == null) {
SWT.error(SWT.ERROR_NULL_ARGUMENT);
}
Point sel = getSelectionRange();
replaceTextRange(sel.x, sel.y, string);
}
void insertBlockSelectionText(String text, int action) {
int firstLine = getLineIndex(blockYAnchor - getVerticalScrollOffset()... |
public void wake () {
synchronized (Device.class) {
if (isDisposed ()) error (SWT.ERROR_DEVICE_DISPOSED);
if (thread == Thread.currentThread ()) return;
wakeThread ();
}
}
void wakeThread () {
NSObject object = new NSObject().alloc().init();
object.performSelectorOnMainThread(OS.sel_release, null, false);
}
... | public void wake () {
synchronized (Device.class) {
if (isDisposed ()) error (SWT.ERROR_DEVICE_DISPOSED);
if (thread == Thread.currentThread ()) return;
wakeThread ();
}
}
void wakeThread () {
NSObject object = new NSObject().alloc().init();
object.performSelectorOnMainThread(OS.sel_release, null, false);
}
... |
private Class findClassInComponents(String name) throws ClassNotFoundException {
// we need to search the components of the path to see if we can find the
// class we want.
InputStream stream = null;
String classFilename = getClassFilename(name);
try {
for (Enum... | private Class findClassInComponents(String name) throws ClassNotFoundException {
// we need to search the components of the path to see if we can find the
// class we want.
InputStream stream = null;
String classFilename = getClassFilename(name);
try {
for (Enum... |
public String getText () {
checkWidget ();
return text;
}
float getThemeAlpha () {
return 0.25f * parent.getThemeAlpha ();
}
| public String getText () {
checkWidget ();
return text;
}
float getThemeAlpha () {
return (background != null ? 1 : 0.25f) * parent.getThemeAlpha ();
}
|
public int getSelectionIndex () {
checkWidget ();
return OS.GetControl32BitValue (handle) - 1;
}
float getThemeAlpha () {
return 0.25f * parent.getThemeAlpha ();
}
| public int getSelectionIndex () {
checkWidget ();
return OS.GetControl32BitValue (handle) - 1;
}
float getThemeAlpha () {
return (background != null ? 1 : 0.25f) * parent.getThemeAlpha ();
}
|
public int getSelectionIndex () {
checkWidget ();
NSTabViewItem selected = ((NSTabView)view).selectedTabViewItem();
if (selected == null) return -1;
for (int i = 0; i < itemCount; i++) {
if (items[i].nsItem.id == selected.id) return i;
}
return -1;
}
float getThemeAlpha () {
return 0.25f * parent.getThemeAlp... | public int getSelectionIndex () {
checkWidget ();
NSTabViewItem selected = ((NSTabView)view).selectedTabViewItem();
if (selected == null) return -1;
for (int i = 0; i < itemCount; i++) {
if (items[i].nsItem.id == selected.id) return i;
}
return -1;
}
float getThemeAlpha () {
return (background != null ? 1 : ... |
public void rsetProperties(Properties p) throws RemoteException, IllegalStateException {
checkOwner("setProperties");
if(remotelySetProperties != null) {
Properties jmeterProperties = JMeterUtils.getJMeterProperties();
log.info("Cleaning previously set properties "+remotelySe... | public void rsetProperties(Properties p) throws RemoteException, IllegalStateException {
checkOwner("setProperties");
if(remotelySetProperties != null) {
Properties jmeterProperties = JMeterUtils.getJMeterProperties();
log.info("Cleaning previously set properties "+remotelySe... |
public int /*long*/ method17 (int /*long*/[] args) {return Show (args[0]);}
};
}
void disposeCOMInterfaces () {
if (supports != null) {
supports.dispose ();
supports = null;
}
if (filePicker != null) {
filePicker.dispose ();
filePicker = null;
}
}
int /*long*/ getAddress () {
return filePicker.getAd... | public int /*long*/ method17 (int /*long*/[] args) {return Show (args[0]);}
};
}
void disposeCOMInterfaces () {
if (supports != null) {
supports.dispose ();
supports = null;
}
if (filePicker != null) {
filePicker.dispose ();
filePicker = null;
}
}
int /*long*/ getAddress () {
return filePicker.getAd... |
public int /*long*/ method4 (int /*long*/[] args) {return PromptForSaveToFile (args[0], args[1], args[2], args[3], args[4]);}
};
}
void disposeCOMInterfaces () {
if (supports != null) {
supports.dispose ();
supports = null;
}
if (helperAppLauncherDialog != null) {
helperAppLauncherDialog.dispose ();
h... | public int /*long*/ method4 (int /*long*/[] args) {return PromptForSaveToFile (args[0], args[1], args[2], args[3], args[4]);}
};
}
void disposeCOMInterfaces () {
if (supports != null) {
supports.dispose ();
supports = null;
}
if (helperAppLauncherDialog != null) {
helperAppLauncherDialog.dispose ();
h... |
public int /*long*/ method7 (int /*long*/[] args) {return IsNonBlocking (args[0]);}
};
}
void disposeCOMInterfaces () {
if (inputStream != null) {
inputStream.dispose ();
inputStream = null;
}
}
int /*long*/ getAddress () {
return inputStream.getAddress ();
}
int /*long*/ QueryInterface (int /*long*/ riid... | public int /*long*/ method7 (int /*long*/[] args) {return IsNonBlocking (args[0]);}
};
}
void disposeCOMInterfaces () {
if (inputStream != null) {
inputStream.dispose ();
inputStream = null;
}
}
int /*long*/ getAddress () {
return inputStream.getAddress ();
}
int /*long*/ QueryInterface (int /*long*/ riid... |
public void test_printLorg_eclipse_swt_printing_Printer() {
// if there aren't any printers, don't do this test
if (Printer.getDefaultPrinterData() == null) return;
boolean exceptionThrown = false;
try {
text.print(null);
} catch (IllegalArgumentException ex) {
exceptionThrown = true;
}
assertTrue("no exce... | public void test_printLorg_eclipse_swt_printing_Printer() {
// if there aren't any printers, don't do this test
if (Printer.getDefaultPrinterData() == null) return;
boolean exceptionThrown = false;
try {
text.print((Printer) null);
} catch (IllegalArgumentException ex) {
exceptionThrown = true;
}
assertTru... |
public boolean isVisible () {
checkWidget();
return OS.IsControlVisible (topHandle ());
}
Decorations menuShell () {
return parent.menuShell ();
}
int kEventAccessibleGetChildAtPoint (int nextHandler, int theEvent, int userData) {
if (accessible != null) {
return accessible.internal_kEventAccessibleGetChildAtPo... | public boolean isVisible () {
checkWidget();
return OS.IsControlVisible (topHandle ());
}
Decorations menuShell () {
return parent.menuShell ();
}
int kEventAccessibleGetChildAtPoint (int nextHandler, int theEvent, int userData) {
if (accessible != null) {
return accessible.internal_kEventAccessibleGetChildAtPo... |
public void map(boolean adapt) {
ClassMapping sup = cls.getMappedPCSuperclassMapping();
if (sup == null || cls.getEmbeddingMetaData() != null)
throw new MetaDataException(_loc.get("not-sub", cls));
ClassMappingInfo info = cls.getMappingInfo();
info.assertNoSchemaComponen... | public void map(boolean adapt) {
ClassMapping sup = cls.getMappedPCSuperclassMapping();
if (sup == null || cls.getEmbeddingMetaData() != null)
throw new MetaDataException(_loc.get("not-sub", cls));
ClassMappingInfo info = cls.getMappingInfo();
info.assertNoSchemaComponen... |
private void registerOptions(final BcelWeaver weaver, final ClassLoader loader, final List definitions) {
StringBuffer allOptions = new StringBuffer();
for (Iterator iterator = definitions.iterator(); iterator.hasNext();) {
Definition definition = (Definition) iterator.next();
... | private void registerOptions(final BcelWeaver weaver, final ClassLoader loader, final List definitions) {
StringBuffer allOptions = new StringBuffer();
for (Iterator iterator = definitions.iterator(); iterator.hasNext();) {
Definition definition = (Definition) iterator.next();
... |
private void initWorldAndWeaver(AjCompilerOptions options) {
cpManager = new EclipseClassPathManager(nameEnvironment);
myBcelWorld = new BcelWorld(cpManager,new UnhandledMessageHandler(getProject()),null /*(xrefHandler)*/);
myBcelWorld.setBehaveInJava5Way(options.behaveInJava5Way);
myBcelWorld.setXnoInline(opt... | private void initWorldAndWeaver(AjCompilerOptions options) {
cpManager = new EclipseClassPathManager(nameEnvironment);
myBcelWorld = new BcelWorld(cpManager,new UnhandledMessageHandler(getProject()),null /*(xrefHandler)*/);
myBcelWorld.setBehaveInJava5Way(options.behaveInJava5Way);
myBcelWorld.setXnoInline(opt... |
public void testAjcLTWAroundInlineMungerTest_Xreweavable() {
runTest("AjcLTW AroundInlineMungerTest -Xreweavable");
}
| public void testAjcLTWAroundInlineMungerTest_Xreweavable() {
runTest("AjcLTW AroundInlineMungerTest");
}
|
public boolean munge(BcelClassWeaver weaver) {
ContextToken tok = CompilationAndWeavingContext.enteringPhase(CompilationAndWeavingContext.MUNGING_WITH, this);
boolean changed = false;
boolean worthReporting = true;
if (munger.getKind() == ResolvedTypeMunger.Field) {
changed = mungeNewField(weaver, (NewFi... | public boolean munge(BcelClassWeaver weaver) {
ContextToken tok = CompilationAndWeavingContext.enteringPhase(CompilationAndWeavingContext.MUNGING_WITH, this);
boolean changed = false;
boolean worthReporting = true;
if (munger.getKind() == ResolvedTypeMunger.Field) {
changed = mungeNewField(weaver, (NewFi... |
public void onClick()
{
item.modelChanging();
// Remove item and invalidate listView
getList().remove(item.getModelObject());
item.modelChanged();
}
};
}
| public void onClick()
{
item.modelChanging();
// Remove item and invalidate listView
getList().remove(item.getModelObject());
ListView.this.modelChanged();
}
};
}
|
public ImageList (int style) {
this.style = style;
int flags = OS.ILC_MASK;
if (OS.IsWinCE) {
flags |= OS.ILC_COLOR;
} else {
if (OS.COMCTL32_MAJOR >= 6 && OS.IsAppThemed ()) {
flags |= OS.ILC_COLOR32;
} else {
int hDC = OS.GetDC (0);
int bits = OS.GetDeviceCaps (hDC, OS.BITSPIXEL);
int planes = O... | public ImageList (int style) {
this.style = style;
int flags = OS.ILC_MASK;
if (OS.IsWinCE) {
flags |= OS.ILC_COLOR;
} else {
if (OS.COMCTL32_MAJOR >= 6) {
flags |= OS.ILC_COLOR32;
} else {
int hDC = OS.GetDC (0);
int bits = OS.GetDeviceCaps (hDC, OS.BITSPIXEL);
int planes = OS.GetDeviceCaps (hDC,... |
public void beforeCallComponent(final Component component,
final RequestListenerInterface listener)
{
}
/**
* A component was added.
*
* @param <V>
* The type
* @param component
* The component that was added
*/
final <V> void componentAdded(final Component<V> component)
{... | public void beforeCallComponent(final Component component,
final RequestListenerInterface listener)
{
}
/**
* A component was added.
*
* @param <V>
* The type
* @param component
* The component that was added
*/
final <V> void componentAdded(final Component<V> component)
{... |
protected final void onComponentTagBody(final MarkupStream markupStream, final ComponentTag openTag)
{
// We are able to automatically add <head> to the page if it is
// missing. But we only want to add it, if we have content to be
// written to its body. Thus we first write the output into a
// StringRespons... | protected final void onComponentTagBody(final MarkupStream markupStream, final ComponentTag openTag)
{
// We are able to automatically add <head> to the page if it is
// missing. But we only want to add it, if we have content to be
// written to its body. Thus we first write the output into a
// StringRespons... |
protected final void onComponentTagBody(MarkupStream markupStream, ComponentTag openTag)
{
// In any case, first render the header section directly associated
// with the markup
super.onComponentTagBody(markupStream, openTag);
// If the parent component is a Page (or a bordered Page), we must
// now includ... | protected final void onComponentTagBody(MarkupStream markupStream, ComponentTag openTag)
{
// In any case, first render the header section directly associated
// with the markup
super.onComponentTagBody(markupStream, openTag);
// If the parent component is a Page (or a bordered Page), we must
// now includ... |
public StringDatatypeValidator ( DatatypeValidator base, Hashtable facets,
boolean derivedByList ) throws InvalidDatatypeFacetException {
setBasetype( base ); // Set base type
// Set Facets if any defined
//fFacetsDefined = 0;
if ( facets != ... | public StringDatatypeValidator ( DatatypeValidator base, Hashtable facets,
boolean derivedByList ) throws InvalidDatatypeFacetException {
setBasetype( base ); // Set base type
// Set Facets if any defined
//fFacetsDefined = 0;
if ( facets != ... |
public URIReferenceDatatypeValidator ( DatatypeValidator base, Hashtable facets,
boolean derivedByList ) throws InvalidDatatypeFacetException {
setBasetype( base ); // Set base type
// Set Facets if any defined
if ( facets != null ){
if ( derivedByList ... | public URIReferenceDatatypeValidator ( DatatypeValidator base, Hashtable facets,
boolean derivedByList ) throws InvalidDatatypeFacetException {
setBasetype( base ); // Set base type
// Set Facets if any defined
if ( facets != null ){
if ( derivedByList ... |
protected void sendFile(FTPClient ftp, String dir, String filename)
throws IOException, BuildException {
InputStream instream = null;
try {
// XXX - why not simply new File(dir, filename)?
File file = getProject().resolveFile(new File(dir, filename).getPath());
... | protected void sendFile(FTPClient ftp, String dir, String filename)
throws IOException, BuildException {
InputStream instream = null;
try {
// XXX - why not simply new File(dir, filename)?
File file = getProject().resolveFile(new File(dir, filename).getPath());
... |
public void showSelection () {
checkWidget ();
if (selectedItems.length == 0) return;
showItem (selectedItems [0]);
}
void sort (int [] items) {
/* Shell Sort from K&R, pg 108 */
int length = items.length;
for (int gap=length/2; gap>0; gap/=2) {
for (int i=gap; i<length; i++) {
for (int j=i-gap; j>=0; j-=gap... | public void showSelection () {
checkWidget ();
if (selectedItems.length == 0) return;
showItem (selectedItems [0]);
}
void sort (int [] items) {
/* Shell Sort from K&R, pg 108 */
int length = items.length;
for (int gap=length/2; gap>0; gap/=2) {
for (int i=gap; i<length; i++) {
for (int j=i-gap; j>=0; j-=gap... |
public void showSelection () {
checkWidget ();
if (selectedItems.length == 0) return;
showItem (selectedItems [0]);
}
void updateColumnWidth (TreeColumn column, int width) {
headerHideToolTip ();
int oldWidth = column.width;
int columnX = column.getX ();
int x = columnX + oldWidth - 1; /* -1 ensures that grid li... | public void showSelection () {
checkWidget ();
if (selectedItems.length == 0) return;
showItem (selectedItems [0]);
}
void updateColumnWidth (TreeColumn column, int width) {
headerHideToolTip ();
int oldWidth = column.width;
int columnX = column.getX ();
int x = columnX + oldWidth - 1; /* -1 ensures that grid li... |
public OutputStream getOutputStream() {
if (STDOUT.equals(value)) {
return new KeepAliveOutputStream(System.out);
} else if (STDERR.equals(value)) {
return new KeepAliveOutputStream(System.err);
}
File f = project.resolveFile(value);
try {
... | public OutputStream getOutputStream() {
if (STDOUT.equals(value)) {
return new KeepAliveOutputStream(System.out);
} else if (STDERR.equals(value)) {
return new KeepAliveOutputStream(System.err);
}
File f = getProject().resolveFile(value);
try {
... |
private void serializeCascades(ValueMetaData vmd)
throws SAXException {
Collection<String> cascades = null;
if (vmd.getCascadePersist() == ValueMetaData.CASCADE_IMMEDIATE) {
if (cascades == null)
cascades = new ArrayList<String>();
cascades.add("cascad... | private void serializeCascades(ValueMetaData vmd)
throws SAXException {
Collection<String> cascades = null;
if (vmd.getCascadePersist() == ValueMetaData.CASCADE_IMMEDIATE) {
if (cascades == null)
cascades = new ArrayList<String>();
cascades.add("cascad... |
public void put(Object key, Object value) {
// TODO check for duplicate aliases?
TupleElementImpl<?> element = new TupleElementImpl(value.getClass());
element.setAlias((String) key);
element.setValue(value);
elements.add(element);
}
| public void put(Object key, Object value) {
// TODO check for duplicate aliases?
TupleElementImpl<?> element = new TupleElementImpl(value == null ? Object.class : value.getClass());
element.setAlias((String) key);
element.setValue(value);
elements.add(element);
}
|
public void append(String string) {
checkWidget();
if (string == null) {
SWT.error(SWT.ERROR_NULL_ARGUMENT);
}
int lastChar = Math.max(getCharCount(), 0);
replaceTextRange(lastChar, 0, string);
}
/**
* Calculates the width of the widest visible line.
*/
void calculateContentWidth() {
lineCache = getLineCac... | public void append(String string) {
checkWidget();
if (string == null) {
SWT.error(SWT.ERROR_NULL_ARGUMENT);
}
int lastChar = Math.max(getCharCount(), 0);
replaceTextRange(lastChar, 0, string);
}
/**
* Calculates the width of the widest visible line.
*/
void calculateContentWidth() {
lineCache = getLineCac... |
private static void printTargets(Project project, Vector names,
Vector descriptions, Vector dependencies,
String heading,
int maxlen) {
// now, start printing the targets and their descriptions
... | private static void printTargets(Project project, Vector names,
Vector descriptions, Vector dependencies,
String heading,
int maxlen) {
// now, start printing the targets and their descriptions
... |
protected void onBeforeRender()
{
super.onBeforeRender();
if (getType() == null)
{
// Set the type, but only if it's not a String (see WICKET-606).
// Otherwise, getConvertEmptyInputStringToNull() won't work.
Class type = getModelType(getModel());
if (String.class.equals(type))
{
setType(type... | protected void onBeforeRender()
{
super.onBeforeRender();
if (getType() == null)
{
// Set the type, but only if it's not a String (see WICKET-606).
// Otherwise, getConvertEmptyInputStringToNull() won't work.
Class type = getModelType(getModel());
if (!String.class.equals(type))
{
setType(typ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.