buggy_function stringlengths 1 391k | fixed_function stringlengths 0 392k |
|---|---|
scrollX = scrollY = -1;
/*******************************************************************************
* Copyright (c) 2000, 2003 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompan... | scrollX = scrollY = -1;
/*******************************************************************************
* Copyright (c) 2000, 2003 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompan... |
public String getResourceStreamLocator()
{
return Stringz.className(application.getResourceSettings().getResourceStreamLocator());
}
| public String getResourceStreamLocator()
{
return Stringz.className(application.getResourceSettings().getResourceStreamFactory());
}
|
private IResourceStream getResourceStream(final Component component)
{
final IResourceStream resourceStream;
String filePath = this.xslFile;
if (filePath == null)
{
filePath = component.findParentWithAssociatedMarkup().getClass().getPackage().getName()
.replace('.', '/')
+ "/" + component.getId(... | private IResourceStream getResourceStream(final Component component)
{
final IResourceStream resourceStream;
String filePath = this.xslFile;
if (filePath == null)
{
filePath = component.findParentWithAssociatedMarkup().getClass().getPackage().getName()
.replace('.', '/')
+ "/" + component.getId(... |
public Properties get(final Class clazz, final String style, final Locale locale)
{
final String key = createResourceKey(clazz, locale, style);
Properties props = propertiesCache.get(key);
if ((props == null) && (propertiesCache.containsKey(key) == false))
{
final IResourceStream resource = resourceSetting... | public Properties get(final Class clazz, final String style, final Locale locale)
{
final String key = createResourceKey(clazz, locale, style);
Properties props = propertiesCache.get(key);
if ((props == null) && (propertiesCache.containsKey(key) == false))
{
final IResourceStream resource = resourceSetting... |
public Point computeSize (int wHint, int hHint, boolean changed) {
checkWidget ();
int width = 0, height = 0;
if (wHint != SWT.DEFAULT) {
width = wHint;
} else {
if (columns.length == 0) {
for (int i = 0; i < itemsCount; i++) {
Rectangle itemBounds = items [i].getBounds ();
width = Math.max (width, i... | public Point computeSize (int wHint, int hHint, boolean changed) {
checkWidget ();
int width = 0, height = 0;
if (wHint != SWT.DEFAULT) {
width = wHint;
} else {
if (columns.length == 0) {
for (int i = 0; i < itemsCount; i++) {
Rectangle itemBounds = items [i].getBounds ();
width = Math.max (width, i... |
protected XSParticleDecl checkOccurrences(XSParticleDecl particle,
String particleName, Element parent,
int allContextFlags,
long defaultVals) {
int min = particle.fMinOccurs;
int max = particle.fMaxOccurs;
boolean defaultMin = (defaultVals & (1 <... | protected XSParticleDecl checkOccurrences(XSParticleDecl particle,
String particleName, Element parent,
int allContextFlags,
long defaultVals) {
int min = particle.fMinOccurs;
int max = particle.fMaxOccurs;
boolean defaultMin = (defaultVals & (1 <... |
public void run() {
waitForSignals();
}
};
waiter.setDaemon(true);
waiter.start();
}
} catch (Exception err) {
stopTest();
StringWriter string = new StringWriter();... | public void run() {
waitForSignals();
}
};
waiter.setDaemon(true);
waiter.start();
}
} catch (Exception err) {
stopTest();
StringWriter string = new StringWriter();... |
private final void checkDuplicates(QName qname, XMLAttributesImpl attributes){
// Example: <foo xmlns:a='NS' xmlns:b='NS' a:attr='v1' b:attr='v2'/>
// search if such attribute already exists
for (int i = 0; i < fLength; i++) {
if (qname.uri == fUri[i] && fLocalpart[i].equals(qna... | private final void checkDuplicates(QName qname, XMLAttributesImpl attributes){
// Example: <foo xmlns:a='NS' xmlns:b='NS' a:attr='v1' b:attr='v2'/>
// search if such attribute already exists
for (int i = 0; i < fLength; i++) {
if (qname.uri == fUri[i] && fLocalpart[i].equals(qna... |
public String[] mapFileName(String sourceFileName) {
try {
Reader stringReader = new StringReader(sourceFileName);
ChainReaderHelper helper = new ChainReaderHelper();
helper.setBufferSize(BUFFER_SIZE);
helper.setPrimaryReader(stringReader);
helper.... | public String[] mapFileName(String sourceFileName) {
try {
Reader stringReader = new StringReader(sourceFileName);
ChainReaderHelper helper = new ChainReaderHelper();
helper.setBufferSize(BUFFER_SIZE);
helper.setPrimaryReader(stringReader);
helper.... |
protected synchronized void dieOnCircularReference(Stack stk, Project p) {
if (isChecked()) {
return;
}
if (isReference()) {
super.dieOnCircularReference(stk, p);
} else {
if (archive != null) {
pushAndInvokeCircularReferenceCheck(a... | protected synchronized void dieOnCircularReference(Stack<Object> stk, Project p) {
if (isChecked()) {
return;
}
if (isReference()) {
super.dieOnCircularReference(stk, p);
} else {
if (archive != null) {
pushAndInvokeCircularReferenc... |
protected InputStream openInputStream(ClassLoader cl) throws IOException {
Class clazz;
String constant = getName();
int index1 = constant.lastIndexOf('.');
if (index1 < 0) {
throw new IOException("No class name in " + constant);
}
int index = index1;
... | protected InputStream openInputStream(ClassLoader cl) throws IOException {
Class<?> clazz;
String constant = getName();
int index1 = constant.lastIndexOf('.');
if (index1 < 0) {
throw new IOException("No class name in " + constant);
}
int index = index1;
... |
protected synchronized void dieOnCircularReference(Stack stk, Project p)
throws BuildException {
if (isChecked()) {
return;
}
// check nested collection
super.dieOnCircularReference(stk, p);
if (!isReference()) {
DataType.pushAndInvok... | protected synchronized void dieOnCircularReference(Stack<Object> stk, Project p)
throws BuildException {
if (isChecked()) {
return;
}
// check nested collection
super.dieOnCircularReference(stk, p);
if (!isReference()) {
DataType.push... |
protected void dieOnCircularReference(Stack stk, Project p)
throws BuildException {
if (isChecked()) {
return;
}
if (isReference()) {
super.dieOnCircularReference(stk, p);
} else {
if (nested instanceof DataType) {
pushAndIn... | protected void dieOnCircularReference(Stack<Object> stk, Project p)
throws BuildException {
if (isChecked()) {
return;
}
if (isReference()) {
super.dieOnCircularReference(stk, p);
} else {
if (nested instanceof DataType) {
p... |
public String toString() {
StringBuffer buf = new StringBuffer(
"{containsregexpselector expression: ");
buf.append(userProvidedExpression);
buf.append("}");
return buf.toString();
}
| public String toString() {
StringBuilder buf = new StringBuilder(
"{containsregexpselector expression: ");
buf.append(userProvidedExpression);
buf.append("}");
return buf.toString();
}
|
public String toString() {
StringBuffer buf = new StringBuffer("{containsselector text: ");
buf.append('"').append(contains).append('"');
buf.append(" casesensitive: ");
buf.append(casesensitive ? "true" : "false");
buf.append(" ignorewhitespace: ");
buf.append(ignore... | public String toString() {
StringBuilder buf = new StringBuilder("{containsselector text: ");
buf.append('"').append(contains).append('"');
buf.append(" casesensitive: ");
buf.append(casesensitive ? "true" : "false");
buf.append(" ignorewhitespace: ");
buf.append(igno... |
public String toString() {
StringBuffer buf = new StringBuffer("{dateselector date: ");
buf.append(dateTime);
buf.append(" compare: ").append(when.getValue());
buf.append(" granularity: ");
buf.append(granularity);
if (pattern != null) {
buf.append(" patte... | public String toString() {
StringBuilder buf = new StringBuilder("{dateselector date: ");
buf.append(dateTime);
buf.append(" compare: ").append(when.getValue());
buf.append(" granularity: ");
buf.append(granularity);
if (pattern != null) {
buf.append(" pat... |
public String toString() {
StringBuffer buf = new StringBuffer("{dependselector targetdir: ");
if (targetdir == null) {
buf.append("NOT YET SET");
} else {
buf.append(targetdir.getName());
}
buf.append(" granularity: ");
buf.append(granularity)... | public String toString() {
StringBuilder buf = new StringBuilder("{dependselector targetdir: ");
if (targetdir == null) {
buf.append("NOT YET SET");
} else {
buf.append(targetdir.getName());
}
buf.append(" granularity: ");
buf.append(granularit... |
public String toString() {
StringBuffer buf = new StringBuffer("{depthselector min: ");
buf.append(min);
buf.append(" max: ");
buf.append(max);
buf.append("}");
return buf.toString();
}
| public String toString() {
StringBuilder buf = new StringBuilder("{depthselector min: ");
buf.append(min);
buf.append(" max: ");
buf.append(max);
buf.append("}");
return buf.toString();
}
|
public String toString() {
StringBuffer buf = new StringBuffer("{filenameselector name: ");
if (pattern != null) {
buf.append(pattern);
}
if (regex != null) {
buf.append(regex).append(" [as regular expression]");
}
buf.append(" negate: ").appen... | public String toString() {
StringBuilder buf = new StringBuilder("{filenameselector name: ");
if (pattern != null) {
buf.append(pattern);
}
if (regex != null) {
buf.append(regex).append(" [as regular expression]");
}
buf.append(" negate: ").app... |
public String toString() {
StringBuffer buf = new StringBuffer();
if (hasSelectors()) {
buf.append("{notselect: ");
buf.append(super.toString());
buf.append("}");
}
return buf.toString();
}
| public String toString() {
StringBuilder buf = new StringBuilder();
if (hasSelectors()) {
buf.append("{notselect: ");
buf.append(super.toString());
buf.append("}");
}
return buf.toString();
}
|
public String toString() {
StringBuffer buf = new StringBuffer("{presentselector targetdir: ");
if (targetdir == null) {
buf.append("NOT YET SET");
} else {
buf.append(targetdir.getName());
}
buf.append(" present: ");
if (destmustexist) {
... | public String toString() {
StringBuilder buf = new StringBuilder("{presentselector targetdir: ");
if (targetdir == null) {
buf.append("NOT YET SET");
} else {
buf.append(targetdir.getName());
}
buf.append(" present: ");
if (destmustexist) {
... |
Enumeration<FileSelector> selectorElements();
/*
* 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 Apach... | Enumeration<FileSelector> selectorElements();
/*
* 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 Apach... |
public String toString() {
StringBuffer buf = new StringBuffer("{sizeselector value: ");
buf.append(sizelimit);
buf.append("compare: ").append(when.getValue());
buf.append("}");
return buf.toString();
}
| public String toString() {
StringBuilder buf = new StringBuilder("{sizeselector value: ");
buf.append(sizelimit);
buf.append("compare: ").append(when.getValue());
buf.append("}");
return buf.toString();
}
|
public TokenizedPath rtrimWildcardTokens() {
StringBuffer sb = new StringBuffer();
int newLen = 0;
for (; newLen < tokenizedPattern.length; newLen++) {
if (SelectorUtils.hasWildcards(tokenizedPattern[newLen])) {
break;
}
if (newLen > 0
... | public TokenizedPath rtrimWildcardTokens() {
StringBuilder sb = new StringBuilder();
int newLen = 0;
for (; newLen < tokenizedPattern.length; newLen++) {
if (SelectorUtils.hasWildcards(tokenizedPattern[newLen])) {
break;
}
if (newLen > 0
... |
public String toString() {
StringBuffer buf = new StringBuffer("{typeselector type: ");
buf.append(type);
buf.append("}");
return buf.toString();
}
| public String toString() {
StringBuilder buf = new StringBuilder("{typeselector type: ");
buf.append(type);
buf.append("}");
return buf.toString();
}
|
Iterator<String> iterator();
/*
* 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 License, Versio... | Iterator<String> iterator();
/*
* 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 License, Versio... |
public String toString() {
StringBuffer buf = new StringBuffer();
buf.append("<ChecksumAlgorithm:");
buf.append("algorithm=").append(algorithm);
buf.append(">");
return buf.toString();
}
| public String toString() {
StringBuilder buf = new StringBuilder();
buf.append("<ChecksumAlgorithm:");
buf.append("algorithm=").append(algorithm);
buf.append(">");
return buf.toString();
}
|
public String toString() {
StringBuffer buf = new StringBuffer();
buf.append("<DigestAlgorithm:");
buf.append("algorithm=").append(algorithm);
buf.append(";provider=").append(provider);
buf.append(">");
return buf.toString();
}
| public String toString() {
StringBuilder buf = new StringBuilder();
buf.append("<DigestAlgorithm:");
buf.append("algorithm=").append(algorithm);
buf.append(";provider=").append(provider);
buf.append(">");
return buf.toString();
}
|
protected void setupDiscovery() {
if (discovery == null && ClientPlugin.getDefault().getPreferenceStore().getBoolean(ClientPlugin.PREF_REGISTER_SERVER)) {
try {
socontainer = SharedObjectContainerFactory
.makeSharedObjectContainer(DISCOVERY_CONTAINER);
discovery = (IDiscoveryContainer) socontainer
... | protected void setupDiscovery() {
if (discovery == null && ClientPlugin.getDefault().getPreferenceStore().getBoolean(ClientPlugin.PREF_REGISTER_SERVER)) {
try {
socontainer = SharedObjectContainerFactory
.getDefault().makeSharedObjectContainer(DISCOVERY_CONTAINER);
discovery = (IDiscoveryContainer) ... |
public boolean getVisible () {
checkWidget();
return (state & HIDDEN) == 0;
}
int getVisibleRegion (int control, boolean clipChildren) {
if (visibleRgn == 0) {
visibleRgn = OS.NewRgn ();
calculateVisibleRegion (control, visibleRgn, clipChildren);
}
int result = OS.NewRgn ();
OS.CopyRgn (visibleRgn, result);
... | public boolean getVisible () {
checkWidget();
return (state & HIDDEN) == 0;
}
int getVisibleRegion (int control, boolean clipChildren) {
if (visibleRgn == 0) {
visibleRgn = OS.NewRgn ();
calculateVisibleRegion (control, visibleRgn, clipChildren);
}
int result = OS.NewRgn ();
OS.CopyRgn (visibleRgn, result);
... |
public static final Object CONTENTS[][] = {
// Internal message formatter messages
{ "BadMajorCode", "The majorCode parameter to createMessage was out of bounds." },
{ "FormatFailed", "An internal error occurred while formatting the following message:\n " },
{ "NoValidatorFor", "No validato... | public static final Object CONTENTS[][] = {
// Internal message formatter messages
{ "BadMajorCode", "The majorCode parameter to createMessage was out of bounds." },
{ "FormatFailed", "An internal error occurred while formatting the following message:\n " },
{ "NoValidatorFor", "No validato... |
public static final String[] fgMessageKeys = {
"BadMajorCode", // 0, "The majorCode parameter to createMessage was out of bounds."
"FormatFailed", // 1, "An internal error occurred while formatting the following message:"
"NoValidatorFor", //... | public static final String[] fgMessageKeys = {
"BadMajorCode", // 0, "The majorCode parameter to createMessage was out of bounds."
"FormatFailed", // 1, "An internal error occurred while formatting the following message:"
"NoValidatorFor", //... |
public void verifyDeleteDetectionOnRefresh(boolean useDataCache,
boolean dirty, LockModeType lock, Class expectedExceptionType) {
OpenJPAEntityManagerFactorySPI emf = (useDataCache)
? emfWithDataCache : emfWithoutDataCache;
OpenJPAEntityManagerSPI em = emf.creat... | public void verifyDeleteDetectionOnRefresh(boolean useDataCache,
boolean dirty, LockModeType lock, Class expectedExceptionType) {
OpenJPAEntityManagerFactorySPI emf = (useDataCache)
? emfWithDataCache : emfWithoutDataCache;
OpenJPAEntityManagerSPI em = emf.creat... |
public void testTwoLevelInheritance() {
EntityManager em = emf.createEntityManager();
// Add two entities, each extending the same mapped interface
em.getTransaction().begin();
SubclassE sc = new SubclassE();
sc.setId(0);
sc.setName("SubclassEBaseClassName");
... | public void testTwoLevelInheritance() {
EntityManager em = emf.createEntityManager();
// Add two entities, each extending the same mapped interface
em.getTransaction().begin();
SubclassE sc = new SubclassE();
sc.setId(0);
sc.setName("SubclassEBaseClassName");
... |
public final static Namespace getNamespaceByName(String name)
throws SecurityException {
debug("getNamespaceByName("+name+")");
Namespace ns = new Namespace(null, name, null, null);
return getNamespace(ns);
}
| public final static Namespace getNamespaceByName(String name)
throws SecurityException {
debug("getNamespaceByName("+name+")");
Namespace ns = new Namespace(null, name, name, null);
return getNamespace(ns);
}
|
private KeyStore getJMeterKeyStore(String keyStorePass, String host) throws GeneralSecurityException, IOException {
final File certFile = new File(CERT_DIRECTORY, CERT_FILE);
final String subject = host == null ? JMETER_SERVER_ALIAS : host;
KeyStore keyStore = null;
final String cano... | private KeyStore getJMeterKeyStore(String keyStorePass, String host) throws GeneralSecurityException, IOException {
final File certFile = new File(CERT_DIRECTORY, CERT_FILE);
final String subject = host == null ? JMETER_SERVER_ALIAS : host;
KeyStore keyStore = null;
final String cano... |
public Point computeSize (int wHint, int hHint, boolean changed) {
checkWidget();
int width = DEFAULT_WIDTH;
int height = DEFAULT_HEIGHT;
if (wHint != SWT.DEFAULT) width = wHint;
if (hHint != SWT.DEFAULT) height = hHint;
int border = getBorderWidth ();
width += border * 2;
height += border * 2;
return new Poin... | public Point computeSize (int wHint, int hHint, boolean changed) {
checkWidget();
int width = DEFAULT_WIDTH;
int height = DEFAULT_HEIGHT;
if (wHint != SWT.DEFAULT) width = wHint;
if (hHint != SWT.DEFAULT) height = hHint;
int border = getBorderWidth ();
width += border * 2;
height += border * 2;
return new Poin... |
protected String getDatePattern()
{
// TODO this is a very shallow implementation; see if there is anything smarter
// to do with the date pattern
Locale locale = Session.get().getLocale();
// now, just try a few that I know of
if (Locale.GERMAN.equals(locale))
{
return "%d.%m.%Y";
}
if ("nl".e... | protected String getDatePattern()
{
// TODO this is a very shallow implementation; see if there is anything smarter
// to do with the date pattern
Locale locale = Session.get().getLocale();
// now, just try a few that I know of
if (Locale.GERMAN.equals(locale))
{
return "%d.%m.%Y";
}
if ("nl".e... |
public void handleEvent(Event event) {
ClipboardProxy clipbordProxy = (ClipboardProxy)display.getData(ID);
if (clipbordProxy == null) return;
display.setData(ID, null);
clipbordProxy.dispose();
}
});
return proxy;
}
ClipboardProxy(Display display) {
this.display = display;
XtConvertSelec... | public void handleEvent(Event event) {
ClipboardProxy clipbordProxy = (ClipboardProxy)display.getData(ID);
if (clipbordProxy == null) return;
display.setData(ID, null);
clipbordProxy.dispose();
}
});
return proxy;
}
ClipboardProxy(Display display) {
this.display = display;
XtConvertSelec... |
public final String getModelObjectAsString()
{
final Object modelObject = getModelObject();
if (modelObject != null)
{
// Get converter
final IConverter converter = getConverter(modelObject.getClass());
// Model string from property
final String modelString = converter.convertToString(modelObject, ... | public final String getModelObjectAsString()
{
final Object modelObject = getModelObject();
if (modelObject != null)
{
// Get converter
final IConverter converter = getConverter(modelObject.getClass());
// Model string from property
final String modelString = converter.convertToString(modelObject, ... |
protected void intersectRanges(Token token) {
RangeToken tok = (RangeToken)token;
if (tok.ranges == null || this.ranges == null)
return;
this.icaseCache = null;
this.sortRanges();
this.compactRanges();
tok.sortRanges();
tok.compactRanges();
... | protected void intersectRanges(Token token) {
RangeToken tok = (RangeToken)token;
if (tok.ranges == null || this.ranges == null)
return;
this.icaseCache = null;
this.sortRanges();
this.compactRanges();
tok.sortRanges();
tok.compactRanges();
... |
public void test2() {
expectBuildException("test2", "manifect file does not exist");
}
| public void test2() {
expectBuildException("test2", "manifest file does not exist");
}
|
private boolean isPrimaryKeyAutoAssigned(List seen) {
if (_autoAssign != null)
return _autoAssign.booleanValue();
Column[] cols = getPrimaryKeyColumns();
if (cols.length == 0) {
_autoAssign = Boolean.FALSE;
return false;
}
for (int i = 0... | private boolean isPrimaryKeyAutoAssigned(List seen) {
if (_autoAssign != null)
return _autoAssign.booleanValue();
Column[] cols = getPrimaryKeyColumns();
if (cols.length == 0) {
_autoAssign = Boolean.FALSE;
return false;
}
for (int i = 0... |
private static boolean flushDirty(StateManagerImpl sm) {
if (!sm.isDirty())
return false;
// only flush if there are actually any dirty non-flushed fields
BitSet dirtyFields = sm.getDirty();
BitSet flushedFields = sm.getFlushed();
for (int i = 0; i < dirtyFields.... | private static boolean flushDirty(StateManagerImpl sm) {
if (!sm.isDirty() || !sm.getBroker().isActive())
return false;
// only flush if there are actually any dirty non-flushed fields
BitSet dirtyFields = sm.getDirty();
BitSet flushedFields = sm.getFlushed();
fo... |
public Properties load(final Class<?> clazz, final String path)
{
// Check the cache
Properties properties = null;
if (propertiesCache != null)
{
properties = propertiesCache.get(path);
}
if (properties == null)
{
IResourceSettings resourceSettings = Application.get().getResourceSettings();
I... | public Properties load(final Class<?> clazz, final String path)
{
// Check the cache
Properties properties = null;
if (propertiesCache != null)
{
properties = propertiesCache.get(path);
}
if (properties == null)
{
IResourceSettings resourceSettings = application.getResourceSettings();
Iterato... |
public void testEnumIdClass() {
EntityManager em = emf.createEntityManager();
Employee e = new Employee();
e.setEmpId(1);
e.setEmpType(Employee.EmpType.A1);
PhoneNumber phoneNumber = new PhoneNumber();
phoneNumber.setNumber(1);
phoneNumber.setEmp(e);
e... | public void testEnumIdClass() {
EntityManager em = emf.createEntityManager();
Employee e = new Employee();
e.setEmpId(1);
e.setEmpType(Employee.EmpType.A1);
PhoneNumber phoneNumber = new PhoneNumber();
phoneNumber.setPhNumber(1);
phoneNumber.setEmp(e);
... |
public static Test suite()
{
TestSuite suite = new TestSuite();
suite.addTest(new FormInputTest("testHelloWorld"));
JettyDecorator deco = new JettyDecorator(suite);
deco.setPort(8098);
deco.setWebappContextRoot("src/webapp");
deco.setContextPath("/wicket-examples");
return deco;
}
| public static Test suite()
{
TestSuite suite = new TestSuite();
suite.addTestSuite(FormInputTest.class);
JettyDecorator deco = new JettyDecorator(suite);
deco.setPort(8098);
deco.setWebappContextRoot("src/webapp");
deco.setContextPath("/wicket-examples");
return deco;
}
|
int traverseLocal(Element elmNode,
/*
* The Apache Software License, Version 1.1
*
*
* Copyright (c) 2001 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 m... | int traverseLocal(Element elmNode,
/*
* The Apache Software License, Version 1.1
*
*
* Copyright (c) 2001 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 m... |
private Hashtable fGroupNameRegistry;
XSDGroupTraverser (XSDHandler handler,
XMLErrorReporter errorReporter,
XSAttributeChecker gAttrCheck) {
super(handler, errorReporter, gAttrCheck);
}
int traverse(Element elmNode,
XSDocumentInf... | private Hashtable fGroupNameRegistry;
XSDGroupTraverser (XSDHandler handler,
XMLErrorReporter errorReporter,
XSAttributeChecker gAttrCheck) {
super(handler, errorReporter, gAttrCheck);
}
int traverseLocal(Element elmNode,
XSDocume... |
protected void checkContent(String content, Object state, Vector enumeration, boolean asBase)
throws InvalidDatatypeValueException {
// validate against parent type if any
if (this.fBaseValidator != null) {
// validate content as a base type
((DecimalDatatypeValidator)fBa... | protected void checkContent(String content, Object state, Vector enumeration, boolean asBase)
throws InvalidDatatypeValueException {
// validate against parent type if any
if (fBaseValidator instanceof DecimalDatatypeValidator) {
// validate content as a base type
((Decim... |
Properties load(final Class< ? > clazz, final String path);
/*
* 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... | Properties load(final Class< ? > clazz, final String path);
/*
* 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... |
public void substring(SQLBuffer buf, FilterValue str, FilterValue start,
FilterValue end) {
buf.append(substringFunctionName).append("(");
str.appendTo(buf);
buf.append(", ");
if (start instanceof Number) {
long startLong = toLong(start);
buf.append(Lo... | public void substring(SQLBuffer buf, FilterValue str, FilterValue start,
FilterValue end) {
buf.append(substringFunctionName).append("(");
str.appendTo(buf);
buf.append(", ");
if (start.getValue() instanceof Number) {
long startLong = toLong(start);
bu... |
private Set parsePersistentTypeNames(ClassLoader loader)
throws IOException {
ClassArgParser cparser = newClassArgParser();
String[] clss;
Set names = new HashSet();
if (files != null) {
File file;
for (Iterator itr = files.iterator(); itr.hasNext();) ... | private Set parsePersistentTypeNames(ClassLoader loader)
throws IOException {
ClassArgParser cparser = newClassArgParser();
String[] clss;
Set names = new HashSet();
if (files != null) {
File file;
for (Iterator itr = files.iterator(); itr.hasNext();) ... |
Element nextNode = traverseAttrsAndAttrGrps(child, attrGrp, schemaDoc, grammar, null);
/*
* The Apache Software License, Version 1.1
*
*
* Copyright (c) 2001, 2002 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are ... | Element nextNode = traverseAttrsAndAttrGrps(child, attrGrp, schemaDoc, grammar, null);
/*
* The Apache Software License, Version 1.1
*
*
* Copyright (c) 2001, 2002 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are ... |
private void doOneJar(File jarSource, File jarTarget)
throws BuildException {
if (JavaEnvUtils.isJavaVersion(JavaEnvUtils.JAVA_1_1)) {
throw new BuildException("The signjar task is only available on "
+ "JDK versions 1.2 or greater");
}
... | private void doOneJar(File jarSource, File jarTarget)
throws BuildException {
if (JavaEnvUtils.isJavaVersion(JavaEnvUtils.JAVA_1_1)) {
throw new BuildException("The signjar task is only available on "
+ "JDK versions 1.2 or greater");
}
... |
public boolean print (GC gc) {
checkWidget ();
if (gc == null) error (SWT.ERROR_NULL_ARGUMENT);
if (gc.isDisposed ()) error (SWT.ERROR_INVALID_ARGUMENT);
if (!OS.IsWinCE && OS.WIN32_VERSION >= OS.VERSION (5, 1)) {
int /*long*/ topHandle = topHandle ();
int /*long*/ hdc = gc.handle;
int state = 0;
int /*long... | public boolean print (GC gc) {
checkWidget ();
if (gc == null) error (SWT.ERROR_NULL_ARGUMENT);
if (gc.isDisposed ()) error (SWT.ERROR_INVALID_ARGUMENT);
if (!OS.IsWinCE && OS.WIN32_VERSION >= OS.VERSION (5, 1)) {
int /*long*/ topHandle = topHandle ();
int /*long*/ hdc = gc.handle;
int state = 0;
int /*long... |
private URI createURI(URL location) {
String locationStr = null;
try {
locationStr = (location == null) ? "" : URLEncoder.encode(location
.toExternalForm(), "UTF-8");
} catch (UnsupportedEncodingException e) {
// should not happen
}
return URI.create(ServiceConstants.PROTOCOL
+ ServiceConstant... | private URI createURI(URL location) {
String locationStr = null;
try {
locationStr = (location == null) ? "" : URLEncoder.encode(location
.toExternalForm(), "UTF-8");
} catch (UnsupportedEncodingException e) {
// should not happen
}
return URI.create(ServiceConstants.PROTOCOL
+ ServiceProperty... |
protected void drawLineBreakSelection(String line, int lineOffset, int paintX, int paintY, GC gc) {
Point selection = parent.internalGetSelection();
int lineLength = line.length();
int selectionStart = Math.max(0, selection.x - lineOffset);
int selectionEnd = selection.y - lineOffset;
int lineEndSpaceWidth = getLi... | protected void drawLineBreakSelection(String line, int lineOffset, int paintX, int paintY, GC gc) {
Point selection = parent.internalGetSelection();
int lineLength = line.length();
int selectionStart = Math.max(0, selection.x - lineOffset);
int selectionEnd = selection.y - lineOffset;
int lineEndSpaceWidth = getLi... |
protected abstract void disposeGC(GC gc);
/**
* Draws a line of text at the specified location.
* </p>
*
* @param line the line to draw
* @param lineIndex index of the line to draw
* @param paintY y location to draw at
* @param gc GC to draw on
* @param widgetBackground the widget background color.
* Used a... | protected abstract void disposeGC(GC gc);
/**
* Draws a line of text at the specified location.
* </p>
*
* @param line the line to draw
* @param lineIndex index of the line to draw
* @param paintY y location to draw at
* @param gc GC to draw on
* @param widgetBackground the widget background color.
* Used a... |
public String getStaticLabel()
{
return ((TestElement)getUserObject()).getPropertyAsString(TestElement.NAME);
}
| public String getStaticLabel()
{
return GuiPackage.getInstance().getGui((TestElement)getUserObject()).getStaticLabel();
}
|
private Object eval(JPQLNode node) {
Value val1 = null;
Value val2 = null;
Value val3 = null;
boolean not = node.not;
switch (node.id) {
case JJTWHERE: // top-level WHERE clause
return getExpression(onlyChild(node));
case JJTBOOLEANL... | private Object eval(JPQLNode node) {
Value val1 = null;
Value val2 = null;
Value val3 = null;
boolean not = node.not;
switch (node.id) {
case JJTWHERE: // top-level WHERE clause
return getExpression(onlyChild(node));
case JJTBOOLEANL... |
private static ResourceReference getYuiLoader()
{
if (YUILOADER == null)
{
StringBuffer sb = new StringBuffer();
sb.append("yuiloader-beta");
if (Application.DEPLOYMENT.equals(Application.get().getConfigurationType()))
{
sb.append("-min");
}
sb.append(".js");
YUILOADER = new JavascriptRes... | private static ResourceReference getYuiLoader()
{
if (YUILOADER == null)
{
StringBuffer sb = new StringBuffer();
sb.append("yuiloader");
if (Application.DEPLOYMENT.equals(Application.get().getConfigurationType()))
{
sb.append("-min");
}
sb.append(".js");
YUILOADER = new JavascriptResource... |
public Decorations (Composite parent, int style) {
super (parent, checkStyle (style));
}
void _setMaximized (boolean maximized) {
swFlags = maximized ? OS.SW_SHOWMAXIMIZED : OS.SW_RESTORE;
if (OS.IsWinCE) {
/*
* Note: WinCE does not support SW_SHOWMAXIMIZED and SW_RESTORE. The
* workaround is to resize the wi... | public Decorations (Composite parent, int style) {
super (parent, checkStyle (style));
}
void _setMaximized (boolean maximized) {
swFlags = maximized ? OS.SW_SHOWMAXIMIZED : OS.SW_RESTORE;
if (OS.IsWinCE) {
/*
* Note: WinCE does not support SW_SHOWMAXIMIZED and SW_RESTORE. The
* workaround is to resize the wi... |
private MarkupResourceStream newMarkupResourceStream(final Class containerClass,
final ContainerInfo containerInfo)
{
IResourceStream markupResource = application.getResourceSettings()
.getResourceStreamLocator().locate(containerClass, containerInfo.getStyle(),
containerInfo.getLocale(), containerInfo.... | private MarkupResourceStream newMarkupResourceStream(final Class containerClass,
final ContainerInfo containerInfo)
{
IResourceStream markupResource = application.getResourceSettings()
.getResourceStreamLocator().locate(containerClass, containerClass.getName().replace('.', '/'),containerInfo.getStyle(),
... |
public CharSequence transform(final Component component, final String output) throws Exception
{
String filepath = component.findParentWithAssociatedMarkup().getClass().getPackage()
.getName().replace('.', '/')
+ "/" + component.getId();
IResourceStream resourceStream = Application.get().getResourceSetti... | public CharSequence transform(final Component component, final String output) throws Exception
{
String filepath = component.findParentWithAssociatedMarkup().getClass().getPackage()
.getName().replace('.', '/')
+ "/" + component.getId();
IResourceStream resourceStream = Application.get().getResourceSetti... |
public final Properties get(final Application application, final Class clazz,
final String style, final Locale locale)
{
final String key = createResourceKey(clazz, locale, style);
Properties props = (Properties)propertiesCache.get(key);
if ((props == null) && (propertiesCache.containsKey(key) == false))
{... | public final Properties get(final Application application, final Class clazz,
final String style, final Locale locale)
{
final String key = createResourceKey(clazz, locale, style);
Properties props = (Properties)propertiesCache.get(key);
if ((props == null) && (propertiesCache.containsKey(key) == false))
{... |
protected void sendMessage(ContainerMessage data) throws IOException {
synchronized (getConnectLock()) {
ID connectedID = getConnectedID();
if (connectedID == null)
throw new ConnectException("Container not connected"); //$NON-NLS-1$
synchronized (getGroupMembershipLock()) {
if (connectedID.equals(d... | protected void sendMessage(ContainerMessage data) throws IOException {
synchronized (getConnectLock()) {
ID connectedID = getConnectedID();
if (connectedID == null)
throw new ConnectException("Container not connected"); //$NON-NLS-1$
synchronized (getGroupMembershipLock()) {
if (!connectedID.equals(... |
public Time lastModifiedTime()
{
if (file != null)
{
long lastModified = file.lastModified();
if (lastModified != this.lastModified)
{
this.lastModified = lastModified;
contentLength = (int)file.length();
}
}
else
{
URLConnection urlConnection = null;
boolean close = false;
try
... | public Time lastModifiedTime()
{
if (file != null)
{
long lastModified = file.lastModified();
if (lastModified != this.lastModified)
{
this.lastModified = lastModified;
contentLength = (int)file.length();
}
}
else
{
URLConnection urlConnection = null;
boolean close = false;
try
... |
protected final void respond(final AjaxRequestTarget target)
{
onTimer(target);
if (!stopped)
{
target.getHeaderResponse().renderOnLoadJavascript(getJsTimeoutCall(updateInterval));
}
}
| protected final void respond(final AjaxRequestTarget target)
{
onTimer(target);
if (!stopped && isEnabled(getComponent()))
{
target.getHeaderResponse().renderOnLoadJavascript(getJsTimeoutCall(updateInterval));
}
}
|
protected void registerJavascriptNamespaces(IHeaderResponse response)
{
response.renderJavascript(
"if (typeof(Wicket)=='undefined') { Wicket={}; } if (typeof('Wicket.Forms')=='undefined') { Wicket.Forms={}; }",
Form.class.getName());
| protected void registerJavascriptNamespaces(IHeaderResponse response)
{
response.renderJavascript(
"if (typeof(Wicket)=='undefined') { Wicket={}; } if (typeof(Wicket.Forms)=='undefined') { Wicket.Forms={}; }",
Form.class.getName());
|
private void unpackAjAttributes(World world) {
associatedShadowMunger = null;
List as = BcelAttributes.readAjAttributes(getDeclaringType().getClassName(),method.getAttributes(), getSourceContext(world),world.getMessageHandler());
processAttributes(world, as);
as = AtAjAttributes.readAj5MethodAttributes(m... | private void unpackAjAttributes(World world) {
associatedShadowMunger = null;
List as = BcelAttributes.readAjAttributes(getDeclaringType().getClassName(),method.getAttributes(), getSourceContext(world),world.getMessageHandler(),bcelObjectType.getWeaverVersionAttribute());
processAttributes(world, as);
as... |
private void printAspectAttributes(PrintStream out) {
ISourceContext context = null;
if (enclosingClass != null && enclosingClass.getType() != null) {
context = enclosingClass.getType().getSourceContext();
}
List as = BcelAttributes.readAjAttributes(getClassName(),attributes, context,null);
if (! as.isEmp... | private void printAspectAttributes(PrintStream out) {
ISourceContext context = null;
if (enclosingClass != null && enclosingClass.getType() != null) {
context = enclosingClass.getType().getSourceContext();
}
List as = BcelAttributes.readAjAttributes(getClassName(),attributes, context,null,AjAttribute.Weaver... |
protected void onComponentTag(final ComponentTag tag)
{
// Default handling for component tag
super.onComponentTag(tag);
// must be attached to <input type="checkbox" .../> tag
checkComponentTag(tag, "input");
checkComponentTagAttribute(tag, "type", "checkbox");
CheckGroup group = (CheckGroup)findParent... | protected void onComponentTag(final ComponentTag tag)
{
// Default handling for component tag
super.onComponentTag(tag);
// must be attached to <input type="checkbox" .../> tag
checkComponentTag(tag, "input");
checkComponentTagAttribute(tag, "type", "checkbox");
CheckGroup group = findParent(CheckGroup.... |
protected final void onComponentTag(final ComponentTag tag)
{
checkComponentTag(tag, "input");
checkComponentTagAttribute(tag, "type", "checkbox");
final String value = getValue();
if (value != null)
{
try
{
if (Strings.isTrue(value))
{
tag.put("checked", "checked");
}
else
{... | protected final void onComponentTag(final ComponentTag tag)
{
checkComponentTag(tag, "input");
checkComponentTagAttribute(tag, "type", "checkbox");
final String value = getValue();
if (value != null)
{
try
{
if (Strings.isTrue(value))
{
tag.put("checked", "checked");
}
else
{... |
protected void onComponentTag(ComponentTag tag)
{
// must be attached to <input type="checkbox" .../> tag
checkComponentTag(tag, "input");
checkComponentTagAttribute(tag, "type", "checkbox");
CheckGroup group = (CheckGroup)findParent(CheckGroup.class);
if (group == null)
{
throw new WicketRuntimeExcep... | protected void onComponentTag(ComponentTag tag)
{
// must be attached to <input type="checkbox" .../> tag
checkComponentTag(tag, "input");
checkComponentTagAttribute(tag, "type", "checkbox");
CheckGroup group = findParent(CheckGroup.class);
if (group == null)
{
throw new WicketRuntimeException(
"... |
protected void onComponentTag(final ComponentTag tag)
{
checkComponentTag(tag, "select");
// Should a roundtrip be made (have onSelectionChanged called) when the
// selection changed?
if (wantOnSelectionChangedNotifications())
{
// url that points to this components IOnChangeListener method
final Cha... | protected void onComponentTag(final ComponentTag tag)
{
checkComponentTag(tag, "select");
// Should a roundtrip be made (have onSelectionChanged called) when the
// selection changed?
if (wantOnSelectionChangedNotifications())
{
// url that points to this components IOnChangeListener method
final Cha... |
public Form getForm()
{
// Look for parent form
final Form form = (Form)findParent(Form.class);
if (form == null)
{
throw new WicketRuntimeException("Could not find Form parent for " + this);
}
return form;
}
| public Form getForm()
{
// Look for parent form
final Form form = findParent(Form.class);
if (form == null)
{
throw new WicketRuntimeException("Could not find Form parent for " + this);
}
return form;
}
|
protected void onComponentTag(final ComponentTag tag)
{
// Default handling for component tag
super.onComponentTag(tag);
// must be attached to <input type="radio" .../> tag
checkComponentTag(tag, "input");
checkComponentTagAttribute(tag, "type", "radio");
final RadioGroup group = (RadioGroup)findParent... | protected void onComponentTag(final ComponentTag tag)
{
// Default handling for component tag
super.onComponentTag(tag);
// must be attached to <input type="radio" .../> tag
checkComponentTag(tag, "input");
checkComponentTagAttribute(tag, "type", "radio");
final RadioGroup group = findParent(RadioGroup.... |
protected final void onComponentTagBody(final MarkupStream markupStream,
final ComponentTag openTag)
{
// Iterate through choices
final List<T> choices = getChoices();
// Buffer to hold generated body
final AppendingStringBuffer buffer = new AppendingStringBuffer((choices.size() + 1) * 70);
// The sele... | protected final void onComponentTagBody(final MarkupStream markupStream,
final ComponentTag openTag)
{
// Iterate through choices
final List<T> choices = getChoices();
// Buffer to hold generated body
final AppendingStringBuffer buffer = new AppendingStringBuffer((choices.size() + 1) * 70);
// The sele... |
public final Form getForm()
{
if (form == null)
{
// Look for parent form
form = (Form)findParent(Form.class);
}
return form;
}
| public final Form getForm()
{
if (form == null)
{
// Look for parent form
form = findParent(Form.class);
}
return form;
}
|
protected void onSubmit()
{
ClientPropertiesBean propertiesBean = (ClientPropertiesBean)getModelObject();
WebRequestCycle requestCycle = (WebRequestCycle)getRequestCycle();
WebSession session = (WebSession)getSession();
ClientInfo clientInfo = session.getClientInfo();
if (clientInfo == null)
{
... | protected void onSubmit()
{
ClientPropertiesBean propertiesBean = getModelObject();
WebRequestCycle requestCycle = (WebRequestCycle)getRequestCycle();
WebSession session = (WebSession)getSession();
ClientInfo clientInfo = session.getClientInfo();
if (clientInfo == null)
{
clientInfo = new We... |
protected IRequestTarget resolveBookmarkablePage(final RequestCycle requestCycle,
final RequestParameters requestParameters)
{
String bookmarkablePageClass = requestParameters.getBookmarkablePageClass();
Session session = requestCycle.getSession();
Class<? extends Page> pageClass;
try
{
pageClass = (C... | protected IRequestTarget resolveBookmarkablePage(final RequestCycle requestCycle,
final RequestParameters requestParameters)
{
String bookmarkablePageClass = requestParameters.getBookmarkablePageClass();
Session session = requestCycle.getSession();
Class<? extends Page> pageClass;
try
{
pageClass = se... |
public IRequestTarget decode(RequestParameters requestParameters)
{
String remainder = requestParameters.getPath().substring(getMountPath().length());
final String parametersFragment;
int ix = remainder.indexOf('/', 1);
if (ix == -1)
{
ix = remainder.length();
parametersFragment = "";
}
else
{
... | public IRequestTarget decode(RequestParameters requestParameters)
{
String remainder = requestParameters.getPath().substring(getMountPath().length());
final String parametersFragment;
int ix = remainder.indexOf('/', 1);
if (ix == -1)
{
ix = remainder.length();
parametersFragment = "";
}
else
{
... |
public final Page newPage(final Class<? extends Page> pageClass)
{
try
{
// throw an exception in case default constructor is missing
// => improved error message
pageClass.getConstructor((Class[])null);
return (Page)pageClass.newInstance();
}
catch (NoSuchMethodException e)
{
// a bit of a ... | public final Page newPage(final Class<? extends Page> pageClass)
{
try
{
// throw an exception in case default constructor is missing
// => improved error message
pageClass.getConstructor((Class[])null);
return pageClass.newInstance();
}
catch (NoSuchMethodException e)
{
// a bit of a hack h... |
private IModel originalModel;
/**
* Construct.
*
* @param component
* subject of the change
*/
ModelChange(final Component<?> component)
{
if (component == null)
{
throw new IllegalArgumentException("argument component must be not null");
}
// Save component
this.component = com... | private IModel originalModel;
/**
* Construct.
*
* @param component
* subject of the change
*/
ModelChange(final Component<?> component)
{
if (component == null)
{
throw new IllegalArgumentException("argument component must be not null");
}
// Save component
this.component = com... |
public void testFormProcessing()
{
// THIS NEEDS TO BE REWRITTEN BASED ON 1_2 VERSION
MockModelObject modelObject = new MockModelObject();
MockCheckGroupTestFormPage page = new MockCheckGroupTestFormPage();
// create component hierarchy
final Form<MockModelObject> form = new Form<MockModelObject>(page,... | public void testFormProcessing()
{
// THIS NEEDS TO BE REWRITTEN BASED ON 1_2 VERSION
MockModelObject modelObject = new MockModelObject();
MockCheckGroupTestFormPage page = new MockCheckGroupTestFormPage();
// create component hierarchy
final Form<MockModelObject> form = new Form<MockModelObject>(page,... |
public void testComponentClone()
{
PropertyModel pm = new PropertyModel(new TextField<String>(new MockPageWithOneComponent(), "component",
new Model<String>("test")), "modelObject");
PropertyModel pm2 = (PropertyModel)Objects.cloneModel(pm);
assertTrue(pm.getObject() == pm2.getObject());
}
| public void testComponentClone()
{
PropertyModel pm = new PropertyModel(new TextField<String>(new MockPageWithOneComponent(), "component",
new Model<String>("test")), "modelObject");
PropertyModel pm2 = Objects.cloneModel(pm);
assertTrue(pm.getObject() == pm2.getObject());
}
|
public Address getAddressAt(int index)
{
return (Address)addressList.get(index);
}
| public Address getAddressAt(int index)
{
return addressList.get(index);
}
|
public static final String REMOTESERVICE_NAMESPACE_NAME = "remote.service.namespace";
} | public static final String REMOTESERVICE_NAMESPACE_NAME = "remote.service.namespace"; //$NON-NLS-1$
} |
public Component getListCellRendererComponent(
JList list,
Object value,
int index,
boolean isSelected,
boolean cellHasFocus) {
String label = "<no message>";
String detail = null;
IMessage.Kind kind = IMessage.INFO;
if (value instanceof IMessage) {
IMessag... | public Component getListCellRendererComponent(
JList list,
Object value,
int index,
boolean isSelected,
boolean cellHasFocus) {
String label = "<no message>";
String detail = null;
IMessage.Kind kind = IMessage.ERROR;
if (value instanceof IMessage) {
IMessa... |
public int changeX(int x) {
this.x = x;
return x;
}
void doIt() {
try {
File f = new File(".");
f.getCanonicalPath();
} catch (IOException ioe) {
System.err.println("!");
}
setX(10);
new Point();
}
}
class SubPoint extends Point { }
class Line { }
aspect AdvisesRelationCoverage {
... | public int changeX(int x) {
this.x = x;
return x;
}
void doIt() {
try {
File f = new File(".");
f.getCanonicalPath();
} catch (IOException ioe) {
System.err.println("!");
}
setX(10);
new Point();
}
}
class SubPoint extends Point { }
class Line { }
aspect AdvisesRelationCoverage {
... |
public final boolean resolve(final MarkupContainer container, final MarkupStream markupStream,
final ComponentTag tag)
{
// Must be marked as autolink tag
if (tag.isAutolinkEnabled())
{
// Try to find the Page matching the href
// Note: to not use tag.getId() because it will be modified while
// res... | public final boolean resolve(final MarkupContainer container, final MarkupStream markupStream,
final ComponentTag tag)
{
// Must be marked as autolink tag
if (tag.isAutolinkEnabled())
{
// Try to find the Page matching the href
// Note: to not use tag.getId() because it will be modified while
// res... |
public StoreCache getStoreCache(String cacheName) {
return new StoreCacheImpl(this, _factory.getConfiguration().
getDataCacheManagerInstance().getDataCache(cacheName));
}
| public StoreCache getStoreCache(String cacheName) {
return new StoreCacheImpl(this, _factory.getConfiguration().
getDataCacheManagerInstance().getDataCache(cacheName, true));
}
|
public void sendPostData(URLConnection connection, HTTPSampler sampler)
throws IOException
{
((HttpURLConnection)connection).setRequestMethod("POST");
// If filename was specified then send the post using multipart syntax
String filename = sampler.getFilename();
if ((filename != null) && (filename.trim()... | public void sendPostData(URLConnection connection, HTTPSampler sampler)
throws IOException
{
((HttpURLConnection)connection).setRequestMethod("POST");
// If filename was specified then send the post using multipart syntax
String filename = sampler.getFileField();
if ((filename != null) && (filename.trim(... |
private XpandExecutionContext createXpandExecutionContext (String fileEncoding, Collection<MetaModel> mms, Collection<Outlet> outlets) {
fileEncoding = OldHelper.normalizedFileEncoding (fileEncoding);
final Output output = new OutputImpl ();
for (Outlet outlet: outlets)
... | private XpandExecutionContext createXpandExecutionContext (String fileEncoding, Collection<MetaModel> mms, Collection<Outlet> outlets) {
fileEncoding = OldHelper.normalizedFileEncoding (fileEncoding);
final Output output = new OutputImpl ();
for (Outlet outlet: outlets)
... |
protected void invokeInternal2 (WorkflowContext wfContext, ProgressMonitor monitor, Issues issues) {
// set up the execution context
XpandExecutionContextImpl executionContext = new XpandExecutionContextImpl (getOutput(), null, getGlobalVars (wfContext), null, getNullEvaluationHandler());
... | protected void invokeInternal2 (WorkflowContext wfContext, ProgressMonitor monitor, Issues issues) {
// set up the execution context
XpandExecutionContextImpl executionContext = new XpandExecutionContextImpl (getOutput(), null, getGlobalVars (wfContext), null, getNullEvaluationHandler());
... |
private XpandExecutionContext createCtx(Output out) {
final XpandExecutionContextImpl result = new XpandExecutionContextImpl(
out, null);
Item item = ModelFactory.eINSTANCE.createItem();
EPackage modelPackage = item.eClass().getEPackage();//ModelFactory.eINSTANCE.getModelPackage();
assertNotNull(modelPacka... | private XpandExecutionContext createCtx(Output out) {
final XpandExecutionContextImpl result = new XpandExecutionContextImpl(
out, null);
Item item = ModelFactory.eINSTANCE.createItem();
EPackage modelPackage = item.eClass().getEPackage();//ModelFactory.eINSTANCE.getModelPackage();
assertNotNull(modelPacka... |
protected void setUp() throws Exception {
super.setUp();
execCtx = new XpandExecutionContextImpl(new OutputStringImpl(), null);
execCtx.registerMetaModel(new JavaMetaModel("JavaBeans", new JavaBeansStrategy()));
// ADDED encoding
execCtx.setFileEncoding("ISO-8859-1");
}
| protected void setUp() throws Exception {
super.setUp();
execCtx = new XpandExecutionContextImpl(new OutputStringImpl(), null);
execCtx.registerMetaModel(new JavaMetaModel("JavaBeans", new JavaBeansStrategy()));
// ADDED encoding
execCtx.getResourceManager().setFileEncoding(... |
protected void setUp() throws Exception {
super.setUp();
out = new OutputStringImpl ();
execCtx = new XpandExecutionContextImpl(out, null);
execCtx.registerMetaModel(new JavaMetaModel("JavaBeans", new JavaBeansStrategy()));
// ADDED encoding
execCtx... | protected void setUp() throws Exception {
super.setUp();
out = new OutputStringImpl ();
execCtx = new XpandExecutionContextImpl(out, null);
execCtx.registerMetaModel(new JavaMetaModel("JavaBeans", new JavaBeansStrategy()));
// ADDED encoding
execCtx... |
private XpandExecutionContextImpl createCtx(Output out) {
final XpandExecutionContextImpl result = new XpandExecutionContextImpl(
out, null);
result.setFileEncoding("iso-8859-1");
return result;
}
| private XpandExecutionContextImpl createCtx(Output out) {
final XpandExecutionContextImpl result = new XpandExecutionContextImpl(
out, null);
result.getResourceManager().setFileEncoding("iso-8859-1");
return result;
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.