buggy_function stringlengths 1 391k | fixed_function stringlengths 0 392k |
|---|---|
public static Type[] normalizeUpperBounds(Type[] bounds) {
// don't bother if there's only one (or none) type
if (bounds.length < 2) {
return bounds;
}
Set<Type> types = new HashSet<Type>(bounds.length);
for (Type type1 : bounds) {
boolean subtypeFou... | public static Type[] normalizeUpperBounds(Type[] bounds) {
// don't bother if there's only one (or none) type
if (bounds.length < 2) {
return bounds;
}
Set<Type> types = new HashSet<Type>(bounds.length);
for (Type type1 : bounds) {
boolean subtypeFou... |
public static List<Object[]> setupVersions(){
List<Object[]> data = new ArrayList<Object[]>();
data.add(new Object[] {new TransformersTestParameters(ModelVersion.create(1, 2, 0), TestControllerVersion.V7_1_2_FINAL)});
data.add(new Object[] {new TransformersTestParameters(ModelVersion.create(... | public static List<Object[]> setupVersions(){
List<Object[]> data = new ArrayList<Object[]>();
data.add(new Object[] {new TransformersTestParameters(ModelVersion.create(1, 2, 0), TestControllerVersion.V7_1_2_FINAL)});
data.add(new Object[] {new TransformersTestParameters(ModelVersion.create(... |
public void configure(final DeploymentPhaseContext context, final ComponentConfiguration componentConfiguration, final ViewDescription description, final ViewConfiguration configuration) throws DeploymentUnitProcessingException {
// Create method indexes
DeploymentReflectionIndex reflect... | public void configure(final DeploymentPhaseContext context, final ComponentConfiguration componentConfiguration, final ViewDescription description, final ViewConfiguration configuration) throws DeploymentUnitProcessingException {
// Create method indexes
DeploymentReflectionIndex reflect... |
public void configure(DeploymentPhaseContext context, ComponentConfiguration componentConfiguration, ViewDescription description, ViewConfiguration configuration) throws DeploymentUnitProcessingException {
final Method TO_STRING_METHOD;
try {
TO_STRING_MET... | public void configure(DeploymentPhaseContext context, ComponentConfiguration componentConfiguration, ViewDescription description, ViewConfiguration configuration) throws DeploymentUnitProcessingException {
final Method TO_STRING_METHOD;
try {
TO_STRING_MET... |
public void start(HttpServer httpServer, SecurityRealm securityRealm) {
// The SubjectAssociationHandler wraps all calls to this HttpHandler to ensure the Subject has been associated
// with the security context.
HttpContext context = httpServer.createContext(DOMAIN_API_CONTEXT, new SubjectA... | public void start(HttpServer httpServer, SecurityRealm securityRealm) {
// The SubjectAssociationHandler wraps all calls to this HttpHandler to ensure the Subject has been associated
// with the security context.
HttpContext context = httpServer.createContext(DOMAIN_API_CONTEXT, new SubjectA... |
public Integer getVirtualHostPort(String hostname, boolean securePort) {
ServerHostInfo hostInfo = new ServerHostInfo(hostname);
Host undertowHost = getUndertowHost(hostInfo);
if (undertowHost != null && !undertowHost.getServer().getListeners().isEmpty()) {
if (!securePort) {
... | public Integer getVirtualHostPort(String hostname, boolean securePort) {
ServerHostInfo hostInfo = new ServerHostInfo(hostname);
Host undertowHost = getUndertowHost(hostInfo);
if (undertowHost != null && !undertowHost.getServer().getListeners().isEmpty()) {
if (!securePort) {
... |
public final void start() throws LifecycleException {
ModelControllerClient modelControllerClient = ModelControllerClient.Factory.create(
containerConfig.getManagementAddress(),
containerConfig.getManagementPort(),
getCallbackHandler());
managementCl... | public final void start() throws LifecycleException {
ModelControllerClient modelControllerClient = ModelControllerClient.Factory.create(
containerConfig.getManagementAddress(),
containerConfig.getManagementPort(),
getCallbackHandler());
managementCl... |
protected void doHandle(CommandContext ctx) throws CommandFormatException {
final ParsedCommandLine parsedCmd = ctx.getParsedCommandLine();
String nodePath = this.nodePath.getValue(parsedCmd);
final OperationRequestAddress address;
if (nodePath != null) {
address = new ... | protected void doHandle(CommandContext ctx) throws CommandFormatException {
final ParsedCommandLine parsedCmd = ctx.getParsedCommandLine();
String nodePath = this.nodePath.getValue(parsedCmd);
final OperationRequestAddress address;
if (nodePath != null) {
address = new ... |
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
ArquillianConfig arqConfig = phaseContext.getDeploymentUnit().getAttachment(ArquillianConfig.KEY);
if (arqConfig == null)
return;
ServiceTarget serviceTarget = phaseContext.getSer... | public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
ArquillianConfig arqConfig = phaseContext.getDeploymentUnit().getAttachment(ArquillianConfig.KEY);
if (arqConfig == null)
return;
ServiceTarget serviceTarget = phaseContext.getSer... |
public static void addService(DeploymentPhaseContext phaseContext) {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ServiceTarget serviceTarget = phaseContext.getServiceTarget();
final Deployment deployment = OSGiDeploymentAttachment.getAttachment(deploymentUni... | public static void addService(DeploymentPhaseContext phaseContext) {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ServiceTarget serviceTarget = phaseContext.getServiceTarget();
final Deployment deployment = OSGiDeploymentAttachment.getDeployment(deploymentUni... |
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final ResourceRoot deploymentRoot = phaseContext.getDeploymentUnit().getAttachment(Attachments.DEPLOYMENT_ROOT);
final VirtualFile file = deploymentRoot.getRoot();
if (file == null || !file.ex... | public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final ResourceRoot deploymentRoot = phaseContext.getDeploymentUnit().getAttachment(Attachments.DEPLOYMENT_ROOT);
final VirtualFile file = deploymentRoot.getRoot();
if (file == null || !file.ex... |
public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ModuleSpecification moduleSpecification = deploymentUnit.getAttachment(Attachments.MODULE_SPECIFICATION);
if... | public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ModuleSpecification moduleSpecification = deploymentUnit.getAttachment(Attachments.MODULE_SPECIFICATION);
if... |
private void addDepdenency(ModuleSpecification moduleSpecification, ModuleLoader moduleLoader,
ModuleIdentifier moduleIdentifier) {
moduleSpecification.addDependency(new ModuleDependency(moduleLoader, moduleIdentifier, false, false, false));
}
| private void addDepdenency(ModuleSpecification moduleSpecification, ModuleLoader moduleLoader,
ModuleIdentifier moduleIdentifier) {
moduleSpecification.addSystemDependency(new ModuleDependency(moduleLoader, moduleIdentifier, false, false, false));
}
|
private void addDependency(ModuleSpecification moduleSpecification, ModuleLoader moduleLoader,
ModuleIdentifier moduleIdentifier) {
moduleSpecification.addDependency(new ModuleDependency(moduleLoader, moduleIdentifier, false, false, false));
}
| private void addDependency(ModuleSpecification moduleSpecification, ModuleLoader moduleLoader,
ModuleIdentifier moduleIdentifier) {
moduleSpecification.addSystemDependency(new ModuleDependency(moduleLoader, moduleIdentifier, false, false, false));
}
|
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ModuleLoader moduleLoader = Module.getBootModuleLoader();
final ModuleSpecification moduleSpecification = deploymen... | public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ModuleLoader moduleLoader = Module.getBootModuleLoader();
final ModuleSpecification moduleSpecification = deploymen... |
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ModuleLoader moduleLoader = Module.getBootModuleLoader();
final ModuleSpecification moduleSpecification = deploymen... | public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ModuleLoader moduleLoader = Module.getBootModuleLoader();
final ModuleSpecification moduleSpecification = deploymen... |
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
DeploymentUnit unit = phaseContext.getDeploymentUnit();
DeploymentUnit top = DeploymentUtils.getTopDeploymentUnit(unit);
if (top.hasAttachment(ADDED))
return;
final Resourc... | public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
DeploymentUnit unit = phaseContext.getDeploymentUnit();
DeploymentUnit top = DeploymentUtils.getTopDeploymentUnit(unit);
if (top.hasAttachment(ADDED))
return;
final Resourc... |
public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ModuleSpecification moduleSpecification = deploymentUnit.getAttachment(Attachments.MODULE_SPECIFICATION);
fin... | public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ModuleSpecification moduleSpecification = deploymentUnit.getAttachment(Attachments.MODULE_SPECIFICATION);
fin... |
public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
if (deploymentUnit.hasAttachment(Attachments.OSGI_MANIFEST)) {
return;
}
final ModuleSpecific... | public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
if (deploymentUnit.hasAttachment(Attachments.OSGI_MANIFEST)) {
return;
}
final ModuleSpecific... |
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final ResourceRoot deploymentRoot = phaseContext.getDeploymentUnit().getAttachment(Attachments.DEPLOYMENT_ROOT);
final ModuleSpecification moduleSpecification = phaseContext.getDeploymentUnit().getAtta... | public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final ResourceRoot deploymentRoot = phaseContext.getDeploymentUnit().getAttachment(Attachments.DEPLOYMENT_ROOT);
final ModuleSpecification moduleSpecification = phaseContext.getDeploymentUnit().getAtta... |
public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ModuleSpecification moduleSpecification = deploymentUnit.getAttachment(Attachments.MODULE_SPECIFICATION);
fin... | public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final ModuleSpecification moduleSpecification = deploymentUnit.getAttachment(Attachments.MODULE_SPECIFICATION);
fin... |
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final DeploymentUnit parent = deploymentUnit.getParent() == null ? deploymentUnit : deploymentUnit.getParent();
final Ser... | public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final DeploymentUnit parent = deploymentUnit.getParent() == null ? deploymentUnit : deploymentUnit.getParent();
final Ser... |
public void register(ExtensionBuilder builder) {
builder.service(ApplicationArchiveProcessor.class, DelegatingApplicationArchiveProcessor.class);
builder.service(DeploymentExceptionTransformer.class, ExceptionTransformer.class);
}
| public void register(ExtensionBuilder builder) {
builder.service(ApplicationArchiveProcessor.class, OSGiApplicationArchiveProcessor.class);
builder.service(DeploymentExceptionTransformer.class, ExceptionTransformer.class);
}
|
public void testArountTimeoutInterceptorOrder() throws NamingException {
InterceptorOrder.reset();
InitialContext ctx = new InitialContext();
BeanChild bean = (BeanChild) ctx.lookup("java:module/" + BeanChild.class.getSimpleName());
bean.createTimer();
Assert.assertTrue(BeanP... | public void testArountTimeoutInterceptorOrder() throws NamingException {
InterceptorOrder.reset();
InitialContext ctx = new InitialContext();
BeanChild bean = (BeanChild) ctx.lookup("java:module/" + BeanChild.class.getSimpleName());
bean.createTimer();
Assert.assertTrue(BeanP... |
package org.jboss.as.test.integration.weld.ejb.interceptor.ordering;
/*
* JBoss, Home of Professional Open Source
* Copyright 2012, Red Hat, Inc., and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
* Licensed under the A... | package org.jboss.as.test.integration.weld.ejb.interceptor.ordering;
/*
* JBoss, Home of Professional Open Source
* Copyright 2012, Red Hat, Inc., and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
* Licensed under the A... |
public PrepareStepHandler(final LocalHostControllerInfo localHostControllerInfo,
ContentRepository contentRepository, final Map<String, ProxyController> hostProxies,
final Map<String, ProxyController> serverProxies) {
this.localHostControllerInfo =... | public PrepareStepHandler(final LocalHostControllerInfo localHostControllerInfo,
ContentRepository contentRepository, final Map<String, ProxyController> hostProxies,
final Map<String, ProxyController> serverProxies) {
this.localHostControllerInfo =... |
public void setState(ServerState state) {
this.state = state;
}
void setServerManagementChannel(ManagementChannel serverManagementChannel) {
this.serverManagementChannel = serverManagementChannel;
}
int incrementAndGetRespawnCount() {
return respawnCount.incrementAndGet();
... | public void setState(ServerState state) {
this.state = state;
}
void setServerManagementChannel(ManagementChannel serverManagementChannel) {
this.serverManagementChannel = serverManagementChannel;
}
int incrementAndGetRespawnCount() {
return respawnCount.incrementAndGet();
... |
public static BindInfo bindInfoFor(final String jndiName) {
// TODO: handle non java: schemes
String bindName;
if (jndiName.startsWith("java:")) {
bindName = jndiName.substring(5);
} else if (!jndiName.startsWith("jboss") && !jndiName.startsWith("global") && !jndiName.sta... | public static BindInfo bindInfoFor(final String jndiName) {
// TODO: handle non java: schemes
String bindName;
if (jndiName.startsWith("java:")) {
bindName = jndiName.substring(5);
} else if (!jndiName.startsWith("jboss") && !jndiName.startsWith("global") && !jndiName.sta... |
protected boolean startsWithRoot(String path) {
return path.contains(":\\");
}
| protected boolean startsWithRoot(String path) {
return path.contains(":\\") || path.startsWith("\\\\");
}
|
public static void install(final ServiceTarget serviceTarget, final Endpoint endpoint, final DeploymentUnit unit) {
final ServiceName serviceName = getServiceName(unit, endpoint.getShortName());
final String propContext = endpoint.getName().getKeyProperty(Endpoint.SEPID_PROPERTY_CONTEXT);
fi... | public static void install(final ServiceTarget serviceTarget, final Endpoint endpoint, final DeploymentUnit unit) {
final ServiceName serviceName = getServiceName(unit, endpoint.getShortName());
final String propContext = endpoint.getName().getKeyProperty(Endpoint.SEPID_PROPERTY_CONTEXT);
fi... |
public int read(byte[] bts) throws IOException {
try {
beforeRead(bts.length);
int n = in.read(bts);
afterRead(n);
return n;
} catch (IOException e) {
handleIOException(e);
return -1;
}
}
| public int read(byte[] bts) throws IOException {
try {
beforeRead(bts != null ? bts.length : 0);
int n = in.read(bts);
afterRead(n);
return n;
} catch (IOException e) {
handleIOException(e);
return -1;
}
}
|
public void write(byte[] bts) throws IOException {
try {
beforeWrite(bts.length);
out.write(bts);
afterWrite(bts.length);
} catch (IOException e) {
handleIOException(e);
}
}
| public void write(byte[] bts) throws IOException {
try {
beforeWrite(bts != null ? bts.length : 0);
out.write(bts);
afterWrite(bts.length);
} catch (IOException e) {
handleIOException(e);
}
}
|
public io.undertow.server.session.SessionManager createSessionManager(Deployment deployment) {
SessionContext context = new SessionContextAdapter(deployment);
SessionIdentifierFactory factory = new SessionIdentifierFactoryAdapter(new SecureRandomSessionIdGenerator());
SessionManager<Void> ma... | public io.undertow.server.session.SessionManager createSessionManager(Deployment deployment) {
SessionContext context = new SessionContextAdapter(deployment);
SessionIdentifierFactory factory = new SessionIdentifierFactoryAdapter(new SecureRandomSessionIdGenerator());
SessionManager<LocalSes... |
SessionManager<LocalSessionContext> getSessionManager();
/*
* JBoss, Home of Professional Open Source.
* Copyright 2013, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free ... | SessionManager<LocalSessionContext> getSessionManager();
/*
* JBoss, Home of Professional Open Source.
* Copyright 2013, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free ... |
public void prepare(Map conf, TopologyContext context, BatchOutputCollector batchCollector) {
int thisComponentNumTasks = context.getComponentTasks(context.getThisComponentId()).size();
for(Node n: _nodes) {
if(n.stateInfo!=null) {
State s = n.stateInfo.spec.stateFactory.... | public void prepare(Map conf, TopologyContext context, BatchOutputCollector batchCollector) {
int thisComponentNumTasks = context.getComponentTasks(context.getThisComponentId()).size();
for(Node n: _nodes) {
if(n.stateInfo!=null) {
State s = n.stateInfo.spec.stateFactory.... |
public void testPrependServletPath() throws Exception {
this.request.setContextPath("/myApp");
this.request.setServletPath("/main");
this.request.setPathInfo("/index.html");
String commandName = "myCommand";
String action = "/form.html";
String enctype = "my/enctype";
String method = "POST";
String o... | public void testPrependServletPath() throws Exception {
this.request.setContextPath("/myApp");
this.request.setServletPath("/main");
this.request.setPathInfo("/index.html");
String commandName = "myCommand";
String action = "/form.html";
String enctype = "my/enctype";
String method = "POST";
String o... |
public long getInvocationTimeout() {
return 0;
}
| public long getInvocationTimeout() {
return delegate.getInvocationTimeout();
}
|
public SessionBeanComponentCreateService(final ComponentConfiguration componentConfiguration, final ApplicationExceptions ejbJarConfiguration) {
super(componentConfiguration, ejbJarConfiguration);
final SessionBeanComponentDescription sessionBeanComponentDescription = (SessionBeanComponentDescripti... | public SessionBeanComponentCreateService(final ComponentConfiguration componentConfiguration, final ApplicationExceptions ejbJarConfiguration) {
super(componentConfiguration, ejbJarConfiguration);
final SessionBeanComponentDescription sessionBeanComponentDescription = (SessionBeanComponentDescripti... |
add.get(OP_ADDR).set(new ModelNode().setEmptyList()).add(INTERFACE, "public");
add.get(OP).set(ADD);
add.get(CRITERIA).add().set("inet-address", "127.0.0.1");
nodes.add(add);
}
| add.get(OP_ADDR).set(new ModelNode().setEmptyList()).add(INTERFACE, "public");
add.get(OP).set(ADD);
add.get(CRITERIA).get("inet-address").set("127.0.0.1");
nodes.add(add);
}
|
public ReadResourceHandler() {
this(null, null);
}
ReadResourceHandler(final FilteredData filteredData, OperationStepHandler overrideHandler) {
//todo use AD for validation
validator.registerValidator(ModelDescriptionConstants.RECURSIVE, new ModelTypeValidator(ModelType.BOOLEAN, tru... | public ReadResourceHandler() {
this(null, null);
}
ReadResourceHandler(final FilteredData filteredData, OperationStepHandler overrideHandler) {
//todo use AD for validation
validator.registerValidator(ModelDescriptionConstants.RECURSIVE, new ModelTypeValidator(ModelType.BOOLEAN, tru... |
public void testVarMultInPlace() {
final double v1 = 1.0;
final double c1 = 0.5;
final double v2 = 2.0;
final int id1 = -1;
final int id2 = 3;
final SparseGradient var1 = SparseGradient.createVariable(id1, v1);
final SparseGradient sum = var1.multiply(c1);
... | public void testVarMultInPlace() {
final double v1 = 1.0;
final double c1 = 0.5;
final double v2 = 2.0;
final int id1 = -1;
final int id2 = 3;
final SparseGradient var1 = SparseGradient.createVariable(id1, v1);
final SparseGradient sum = var1.multiply(c1);
... |
protected void handle(CommandContext ctx, String args) {
ModelControllerClient client = ctx.getModelControllerClient();
if(client == null) {
ctx.printLine("The controller client is not available. Make sure you are connected to the controller.");
return;
}
if... | protected void handle(CommandContext ctx, String args) {
ModelControllerClient client = ctx.getModelControllerClient();
if(client == null) {
ctx.printLine("The controller client is not available. Make sure you are connected to the controller.");
return;
}
if... |
public void setUp() {
// Cleanup
resourceRoot = Resource.Factory.create();
registry = TransformerRegistry.Factory.create(null);
resourceRegistration = ManagementResourceRegistration.Factory.create(ROOT);
// test
final Resource toto = Resource.Factory.create();
... | public void setUp() {
// Cleanup
resourceRoot = Resource.Factory.create();
registry = TransformerRegistry.Factory.create(null);
resourceRegistration = ManagementResourceRegistration.Factory.create(ROOT);
// test
final Resource toto = Resource.Factory.create();
... |
private String validate(ModelNode param, ModelNode namespaces) {
String failure = typeValidator.validateParameter(NAMESPACE, param);
String name = param.asProperty().getName();
if (failure == null && !namespaces.isDefined()) {
for (ModelNode node : namespaces.asList()) {
... | private String validate(ModelNode param, ModelNode namespaces) {
String failure = typeValidator.validateParameter(NAMESPACE, param);
String name = param.asProperty().getName();
if (failure == null && namespaces.isDefined()) {
for (ModelNode node : namespaces.asList()) {
... |
private String validate(ModelNode param, ModelNode locations) {
String failure = typeValidator.validateParameter(SCHEMA_LOCATION, param);
String uri = param.asProperty().getName();
if (failure == null && !locations.isDefined()) {
for (ModelNode node : locations.asList()) {
... | private String validate(ModelNode param, ModelNode locations) {
String failure = typeValidator.validateParameter(SCHEMA_LOCATION, param);
String uri = param.asProperty().getName();
if (failure == null && locations.isDefined()) {
for (ModelNode node : locations.asList()) {
... |
package org.springframework.config.java.model;
/*
* Copyright 2002-2008 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/... | package org.springframework.config.java.model;
/*
* Copyright 2002-2008 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/... |
public static void main(String[] args) throws Exception {
TopologyBuilder builder = new TopologyBuilder();
builder.setSpout(1, new TestWordSpout(), 10);
builder.setBolt(2, new ExclamationBolt(), 3)
.shuffleGrouping(1);
builder.setBolt(3, new Exclamati... | public static void main(String[] args) throws Exception {
TopologyBuilder builder = new TopologyBuilder();
builder.setSpout(1, new TestWordSpout(), 10);
builder.setBolt(2, new ExclamationBolt(), 3)
.shuffleGrouping(1);
builder.setBolt(3, new Exclamati... |
public static void main(String[] args) throws Exception {
TopologyBuilder builder = new TopologyBuilder();
builder.setSpout(1, new RandomSentenceSpout(), 5);
builder.setBolt(2, new SplitSentence(), 8)
.shuffleGrouping(1);
builder.setBolt(3,... | public static void main(String[] args) throws Exception {
TopologyBuilder builder = new TopologyBuilder();
builder.setSpout(1, new RandomSentenceSpout(), 5);
builder.setBolt(2, new SplitSentence(), 8)
.shuffleGrouping(1);
builder.setBolt(3,... |
protected <P> void applyUpdate(UpdateContext updateContext, UpdateResultHandler<? super Void, P> resultHandler, P param) {
log.infof("Activating OSGi Subsystem");
// TODO: Hack, which registers the framework module with the {@link ModularURLStreamHandlerFactory}
String value = SystemPropert... | protected <P> void applyUpdate(UpdateContext updateContext, UpdateResultHandler<? super Void, P> resultHandler, P param) {
log.infof("Activating OSGi Subsystem");
// TODO: Hack, which registers the framework module with the {@link ModularURLStreamHandlerFactory}
String value = SystemPropert... |
public void setupFrameworkServices(final BatchBuilder batchBuilder) {
batchBuilder.addService(MBeanServerService.SERVICE_NAME, new MBeanServerService());
TestBundleManagerService.addService(batchBuilder);
FrameworkService.addService(batchBuilder);
PackageAdminService.addService(batch... | public void setupFrameworkServices(final BatchBuilder batchBuilder) {
batchBuilder.addService(MBeanServerService.SERVICE_NAME, new MBeanServerService());
TestBundleManagerService.addService(batchBuilder);
FrameworkService.addService(batchBuilder, null);
PackageAdminService.addService... |
public Object convertToInternal(Object payload, MessageHeaders headers) {
try {
if (byte[].class.equals(getSerializedPayloadClass())) {
ByteArrayOutputStream out = new ByteArrayOutputStream();
JsonEncoding encoding = getJsonEncoding(getMimeType(headers));
// The following has been deprecated as late ... | public Object convertToInternal(Object payload, MessageHeaders headers) {
try {
if (byte[].class.equals(getSerializedPayloadClass())) {
ByteArrayOutputStream out = new ByteArrayOutputStream(1024);
JsonEncoding encoding = getJsonEncoding(getMimeType(headers));
// The following has been deprecated as l... |
protected void renderMergedOutputModel(Map<String, Object> model, HttpServletRequest request,
HttpServletResponse response) throws Exception {
Object toBeMarshalled = locateToBeMarshalled(model);
if (toBeMarshalled == null) {
throw new IllegalStateException("Unable to locate object to be marshalled in model... | protected void renderMergedOutputModel(Map<String, Object> model, HttpServletRequest request,
HttpServletResponse response) throws Exception {
Object toBeMarshalled = locateToBeMarshalled(model);
if (toBeMarshalled == null) {
throw new IllegalStateException("Unable to locate object to be marshalled in model... |
private static final boolean servlet3Present =
ClassUtils.isPresent("javax.servlet.AsyncContext", ServletServerHttpResponse.class.getClassLoader());
| private static final boolean servlet3Present =
ClassUtils.hasMethod(HttpServletResponse.class, "getHeader", String.class);
|
package backtype.storm.metric.api;
package backtype.storm.metric;
public interface IReducer<T> {
T init();
T reduce(T accumulator, Object input);
Object extractResult(T accumulator);
} | package backtype.storm.metric.api;
package backtype.storm.metric.api;
public interface IReducer<T> {
T init();
T reduce(T accumulator, Object input);
Object extractResult(T accumulator);
} |
public static File getTestDirectory() {
if (testDir == null) {
testDir = (new File("test/io/")).getAbsoluteFile();
}
testDir.mkdirs();
return testDir;
}
| public static File getTestDirectory() {
if (testDir == null) {
testDir = new File("test/io/").getAbsoluteFile();
}
testDir.mkdirs();
return testDir;
}
|
private final char commmentStart;
final boolean ignoreSurroundingSpaces;
final boolean ignoreEmptyLines;
final CSVFormat format;
/** The input stream */
final ExtendedBufferedReader in;
Lexer(final CSVFormat format, final ExtendedBufferedReader in) {
this.format = format;
... | private final char commmentStart;
final boolean ignoreSurroundingSpaces;
final boolean ignoreEmptyLines;
final CSVFormat format;
/** The input stream */
final ExtendedBufferedReader in;
Lexer(final CSVFormat format, final ExtendedBufferedReader in) {
this.format = format;
... |
Batcher getBatcher();
/*
* JBoss, Home of Professional Open Source.
* Copyright 2014, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you can redistribute it a... | Batcher getBatcher();
/*
* JBoss, Home of Professional Open Source.
* Copyright 2014, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you can redistribute it a... |
public interface ExtensionContext {
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you can red... | public interface ExtensionContext {
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you can red... |
Cancellable execute(OperationContext context, ModelNode operation, ResultHandler resultHandler);
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of indi... | Cancellable execute(OperationContext context, ModelNode operation, ResultHandler resultHandler);
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of indi... |
Cancellable execute(OperationContext context, ModelNode operation, ResultHandler resultHandler);
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of indi... | Cancellable execute(OperationContext context, ModelNode operation, ResultHandler resultHandler);
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of indi... |
Cancellable execute(OperationContext context, ModelNode operation, ResultHandler resultHandler);
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of indi... | Cancellable execute(OperationContext context, ModelNode operation, ResultHandler resultHandler);
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of indi... |
Cancellable execute(OperationContext context, ModelNode operation, ResultHandler resultHandler);
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of indi... | Cancellable execute(OperationContext context, ModelNode operation, ResultHandler resultHandler);
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of indi... |
public interface OperationContext {
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you can red... | public interface OperationContext {
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you can red... |
Cancellable execute(OperationContext context, ModelNode operation, ResultHandler resultHandler);
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of indi... | Cancellable execute(OperationContext context, ModelNode operation, ResultHandler resultHandler);
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of indi... |
public interface BootOperationContext extends ServerOperationContext {
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
*... | public interface BootOperationContext extends ServerOperationContext {
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
*... |
public interface RuntimeOperationContext extends ServerOperationContext {
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*... | public interface RuntimeOperationContext extends ServerOperationContext {
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*... |
package org.jboss.as.server.legacy;
/*
* JBoss, Home of Professional Open Source.
* Copyright 2010, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you can red... | package org.jboss.as.server.legacy;
/*
* JBoss, Home of Professional Open Source.
* Copyright 2010, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you can red... |
public void integrate(FirstOrderDifferentialEquations equations,
double t0, double[] y0,
double t, double[] y)
throws DerivativeException, IntegratorException {
sanityChecks(equations, t0, y0, t, y);
boolean forward = (t > t0);
// create some internal wo... | public void integrate(FirstOrderDifferentialEquations equations,
double t0, double[] y0,
double t, double[] y)
throws DerivativeException, IntegratorException {
sanityChecks(equations, t0, y0, t, y);
boolean forward = (t > t0);
// create some internal wo... |
public void integrate(FirstOrderDifferentialEquations equations,
double t0, double[] y0,
double t, double[] y)
throws DerivativeException, IntegratorException {
sanityChecks(equations, t0, y0, t, y);
boolean forward = (t > t0);
// create some internal wo... | public void integrate(FirstOrderDifferentialEquations equations,
double t0, double[] y0,
double t, double[] y)
throws DerivativeException, IntegratorException {
sanityChecks(equations, t0, y0, t, y);
boolean forward = (t > t0);
// create some internal wo... |
public static final PathElement FILE_STORE_PATH = PathElement.pathElement(ModelKeys.FILE_STORE, ModelKeys.FILE_STORE_NAME);
// attributes
static final SimpleAttributeDefinition PATH =
new SimpleAttributeDefinitionBuilder(ModelKeys.PATH, ModelType.STRING, true)
.setXmlName(At... | public static final PathElement FILE_STORE_PATH = PathElement.pathElement(ModelKeys.FILE_STORE, ModelKeys.FILE_STORE_NAME);
// attributes
static final SimpleAttributeDefinition PATH =
new SimpleAttributeDefinitionBuilder(ModelKeys.PATH, ModelType.STRING, true)
.setXmlName(At... |
package org.jboss.as.clustering.concurrent;
/*
* JBoss, Home of Professional Open Source.
* Copyright 2013, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you... | package org.jboss.as.clustering.concurrent;
/*
* JBoss, Home of Professional Open Source.
* Copyright 2013, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you... |
package org.jboss.as.test.clustering.cluster.ejb.stateful.bean;
/*
* JBoss, Home of Professional Open Source.
* Copyright 2012, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This i... | package org.jboss.as.test.clustering.cluster.ejb.stateful.bean;
/*
* JBoss, Home of Professional Open Source.
* Copyright 2012, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This i... |
package org.jboss.as.test.clustering.cluster.ejb.stateful.bean;
/*
* JBoss, Home of Professional Open Source
* Copyright 2010, Red Hat Inc., and individual contributors as indicated
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
* This is free ... | package org.jboss.as.test.clustering.cluster.ejb.stateful.bean;
/*
* JBoss, Home of Professional Open Source
* Copyright 2010, Red Hat Inc., and individual contributors as indicated
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
* This is free ... |
public StatelessSession create() throws RemoteException, CreateException;
} | StatelessSession create() throws RemoteException, CreateException;
/*
* JBoss, Home of Professional Open Source.
* Copyright 2008, Red Hat Middleware LLC, and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
... |
public StatelessSessionLocal create() throws CreateException;
} | StatelessSessionLocal create() throws CreateException;
/*
* JBoss, Home of Professional Open Source.
* Copyright 2008, Red Hat Middleware LLC, and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This i... |
import org.jboss.as.controller.security.SubjectUserInfo;
/*
* JBoss, Home of Professional Open Source.
* Copyright 2012, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free ... | import org.jboss.as.controller.security.SubjectUserInfo;
/*
* JBoss, Home of Professional Open Source.
* Copyright 2012, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free ... |
public static Type getType(final ProcessType processType, final RunningMode runningMode) {
if (processType.isServer()) {
if (runningMode == RunningMode.NORMAL) {
return SERVER;
} else {
return MANAGEMENT;
}
... | public void handleRollback(OperationContext context, ModelNode operation) {
// no-op
}
};
/**
* Callback to an {@link OperationStepHandler} indicating that the overall operation is being
* rolled back and the handler should revert any change it ... |
private static final String LANGUAGE_RULES_RN = "org/apache/commons/codec/language/bm/lang.txt";
static {
for (NameType s : NameType.values()) {
Langs.put(s, loadFromResource(LANGUAGE_RULES_RN, Languages.instance(s)));
}
| private static final String LANGUAGE_RULES_RN = "org/apache/commons/codec/language/bm/lang.txt";
static {
for (NameType s : NameType.values()) {
Langs.put(s, loadFromResource(LANGUAGE_RULES_RN, Languages.getInstance(s)));
}
|
public ModelNode getModelDescription(Locale locale) {
return new ModelNode();
}
};
| public ModelNode getModelDescription(Locale locale) {
return CommonDescriptions.getValidateAddressOperation(locale);
}
};
|
public static final ModelNode getUploadDeploymentStreamAttachmentOperation(Locale locale) {
final ResourceBundle bundle = getResourceBundle(locale);
final ModelNode root = new ModelNode();
root.get(OPERATION_NAME).set(UPLOAD_DEPLOYMENT_STREAM);
root.get(DESCRIPTION).set(bundle.getStr... | public static final ModelNode getUploadDeploymentStreamAttachmentOperation(Locale locale) {
final ResourceBundle bundle = getResourceBundle(locale);
final ModelNode root = new ModelNode();
root.get(OPERATION_NAME).set(UPLOAD_DEPLOYMENT_STREAM);
root.get(DESCRIPTION).set(bundle.getStr... |
public ModelNode getModelDescription(Locale locale) {
return PlatformMBeanDescriptions.getDescriptionOnlyOperation(locale, PlatformMBeanConstants.MEMORY + ".gc");
}
| public ModelNode getModelDescription(Locale locale) {
return PlatformMBeanDescriptions.getDescriptionOnlyOperation(locale, "gc", PlatformMBeanConstants.MEMORY);
}
|
public ModelNode getModelDescription(Locale locale) {
return PlatformMBeanDescriptions.getDescriptionOnlyOperation(locale, PlatformMBeanConstants.MEMORY_POOL + ".reset-peak-usage");
}
| public ModelNode getModelDescription(Locale locale) {
return PlatformMBeanDescriptions.getDescriptionOnlyOperation(locale, "reset-peak-usage", PlatformMBeanConstants.MEMORY_POOL);
}
|
private void parseRemoteOutboundConnection(final XMLExtendedStreamReader reader, final ModelNode parentAddress, final List<ModelNode> operations) throws XMLStreamException {
final EnumSet<Attribute> required = EnumSet.of(Attribute.NAME, Attribute.OUTBOUND_SOCKET_BINDING_REF);
final int count = reade... | private void parseRemoteOutboundConnection(final XMLExtendedStreamReader reader, final ModelNode parentAddress, final List<ModelNode> operations) throws XMLStreamException {
final EnumSet<Attribute> required = EnumSet.of(Attribute.NAME, Attribute.OUTBOUND_SOCKET_BINDING_REF);
final int count = reade... |
public Cancellable execute(final NewOperationContext context, final ModelNode operation, final ResultHandler resultHandler) {
Cancellable cancellable = Cancellable.NULL;
try {
final String name = operation.require(NAME).asString();
// Don't require VALUE. ... | public Cancellable execute(final NewOperationContext context, final ModelNode operation, final ResultHandler resultHandler) {
Cancellable cancellable = Cancellable.NULL;
try {
final String name = operation.require(NAME).asString();
// Don't require VALUE. ... |
private void testDeployments(DeploymentExecutor deploymentExecutor) throws Exception {
final MBeanServerConnectionProvider provider = new MBeanServerConnectionProvider(InetAddress.getLocalHost(), 1090);
final MBeanServerConnection mbeanServer = provider.getConnection();
final ObjectName name... | private void testDeployments(DeploymentExecutor deploymentExecutor) throws Exception {
final MBeanServerConnectionProvider provider = MBeanServerConnectionProvider.defaultProvider();
final MBeanServerConnection mbeanServer = provider.getConnection();
final ObjectName name = new ObjectName("j... |
public final void validateAndSet(ModelNode operationObject, final ModelNode model) throws OperationFailedException {
if (isDeprecated()){
ControllerLogger.DEPRECATED_LOGGER.attributeDeprecated(getName());
}
final ModelNode newValue = correctValue(operationObject.get(name), model.... | public final void validateAndSet(ModelNode operationObject, final ModelNode model) throws OperationFailedException {
if (operationObject.hasDefined(name)&&isDeprecated()){
ControllerLogger.DEPRECATED_LOGGER.attributeDeprecated(getName());
}
final ModelNode newValue = correctValue... |
public void unregisterAttribute(String attributeName) {
alreadyRegistered();
}
| public void unregisterAttribute(String attributeName) {
throw alreadyRegistered();
}
|
public void registerOperations(ManagementResourceRegistration resourceRegistration) {
GlobalOperationHandlers.registerGlobalOperations(resourceRegistration, ProcessType.STANDALONE_SERVER);
if (serverEnvironment != null) {
resourceRegistration.registerOperationHandler(ValidateOperationHa... | public void registerOperations(ManagementResourceRegistration resourceRegistration) {
GlobalOperationHandlers.registerGlobalOperations(resourceRegistration, ProcessType.STANDALONE_SERVER);
if (serverEnvironment != null) {
resourceRegistration.registerOperationHandler(ValidateOperationHa... |
private static Method setResultMethod;
static {
try {
jobDetailImplClass = Class.forName("org.quartz.impl.JobDetailImpl");
}
catch (ClassNotFoundException ex) {
jobDetailImplClass = null;
}
try {
Class jobExecutionContextClass =
QuartzJobBean.class.getClassLoader().loadClass("org.quartz.JobEx... | private static Method setResultMethod;
static {
try {
jobDetailImplClass = Class.forName("org.quartz.impl.JobDetailImpl");
}
catch (ClassNotFoundException ex) {
jobDetailImplClass = null;
}
try {
Class jobExecutionContextClass =
QuartzJobBean.class.getClassLoader().loadClass("org.quartz.JobEx... |
String VAULT_OPTIONS = "vault-options";
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you can... | String VAULT_OPTIONS = "vault-options";
/*
* JBoss, Home of Professional Open Source.
* Copyright 2011, Red Hat, Inc., and individual contributors
* as indicated by the @author tags. See the copyright.txt file in the
* distribution for a full listing of individual contributors.
*
* This is free software; you can... |
public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final EEModuleDescription eeModuleDescription = deploymentUnit.getAttachment(org.jboss.as.ee.component.Attachments.EE_MODU... | public void deploy(final DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException {
final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit();
final EEModuleDescription eeModuleDescription = deploymentUnit.getAttachment(org.jboss.as.ee.component.Attachments.EE_MODU... |
protected void initModel(Resource rootResource, ManagementResourceRegistration rootRegistration) {
DomainModelUtil.updateCoreModel(rootResource);
HostModelUtil.createHostRegistry(rootRegistration, hostControllerConfigurationPersister, environment, runningModeControl,
localFileReposit... | protected void initModel(Resource rootResource, ManagementResourceRegistration rootRegistration) {
DomainModelUtil.updateCoreModel(rootResource, environment);
HostModelUtil.createHostRegistry(rootRegistration, hostControllerConfigurationPersister, environment, runningModeControl,
loc... |
public static void installHttpManagementServices(final RunningMode runningMode, final ServiceTarget serviceTarget, final LocalHostControllerInfo hostControllerInfo,
final HostControllerEnvironment environment,
final Servic... | public static void installHttpManagementServices(final RunningMode runningMode, final ServiceTarget serviceTarget, final LocalHostControllerInfo hostControllerInfo,
final HostControllerEnvironment environment,
final Servic... |
protected void initModel(Resource rootResource, ManagementResourceRegistration rootRegistration) {
ServerControllerModelUtil.updateCoreModel(rootResource.getModel());
ServerControllerModelUtil.initOperations(rootRegistration, injectedContentRepository.getValue(),
extensibleConfigurat... | protected void initModel(Resource rootResource, ManagementResourceRegistration rootRegistration) {
ServerControllerModelUtil.updateCoreModel(rootResource.getModel(), configuration.getServerEnvironment());
ServerControllerModelUtil.initOperations(rootRegistration, injectedContentRepository.getValue()... |
protected double computeObjectiveValue(double[] params) {
super.incrementEvaluationCount();
return function.value(params);
}
} | public double computeObjectiveValue(double[] params) {
super.incrementEvaluationCount();
return function.value(params);
}
} |
SimpleAttributeDefinition ALIAS = new SimpleAttributeDefinition(ModelKeys.ALIAS, ModelType.LIST, true);
package org.jboss.as.clustering.infinispan.subsystem;
import org.jboss.as.controller.AttributeDefinition;
import org.jboss.as.controller.SimpleAttributeDefinition;
import org.jboss.as.controller.client.helpers.Meas... | SimpleAttributeDefinition ALIAS = new SimpleAttributeDefinition(ModelKeys.ALIAS, ModelType.LIST, true);
package org.jboss.as.clustering.infinispan.subsystem;
import org.jboss.as.controller.AttributeDefinition;
import org.jboss.as.controller.SimpleAttributeDefinition;
import org.jboss.as.controller.client.helpers.Meas... |
public void testParseSubsystem() throws Exception {
// Parse the subsystem xml into operations
List<ModelNode> operations = super.parse(getSubsystemXml());
/*
// print the operations
System.out.println("List of operations");
for (ModelNode op : operations) {
Sy... | public void testParseSubsystem() throws Exception {
// Parse the subsystem xml into operations
List<ModelNode> operations = super.parse(getSubsystemXml());
/*
// print the operations
System.out.println("List of operations");
for (ModelNode op : operations) {
Sy... |
public void testBagIterator() {
if (!isAddSupported()) {
return;
}
final Bag<T> bag = makeObject();
bag.add((T) "A");
bag.add((T) "A");
bag.add((T) "B");
assertEquals("Bag should have 3 items", 3, bag.size());
final Iterator<T> i = bag.ite... | public void testBagIterator() {
if (!isAddSupported()) {
return;
}
final Bag<T> bag = makeObject();
bag.add((T) "A");
bag.add((T) "A");
bag.add((T) "B");
assertEquals("Bag should have 3 items", 3, bag.size());
final Iterator<T> i = bag.ite... |
private void assertComparatorYieldsOrder(final String[] orderedObjects,
final Comparator<String> comparator) {
final String[] keys = orderedObjects.clone();
// shuffle until the order changes. It's extremely rare that
// this requires more than ... | private void assertComparatorYieldsOrder(final String[] orderedObjects,
final Comparator<String> comparator) {
final String[] keys = orderedObjects.clone();
// shuffle until the order changes. It's extremely rare that
// this requires more than ... |
public void testShrinkCache() {
if (isRemoveSupported() == false || isAddSupported() == false) {
return;
}
resetEmpty();
final NodeCachingLinkedList<E> list = getCollection();
list.addAll(Arrays.asList((E[]) new String[] { "1", "2", "3", "4" }));
list.rem... | public void testShrinkCache() {
if (!isRemoveSupported() || !isAddSupported()) {
return;
}
resetEmpty();
final NodeCachingLinkedList<E> list = getCollection();
list.addAll(Arrays.asList((E[]) new String[] { "1", "2", "3", "4" }));
list.removeAllNodes(); /... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.