buggy_function
stringlengths
1
391k
fixed_function
stringlengths
0
392k
public void configure(final DeploymentPhaseContext context, final ComponentConfiguration componentConfiguration, final ViewDescription description, final ViewConfiguration configuration) throws DeploymentUnitProcessingException { // Add MB association interceptors ...
public void configure(final DeploymentPhaseContext context, final ComponentConfiguration componentConfiguration, final ViewDescription description, final ViewConfiguration configuration) throws DeploymentUnitProcessingException { // Add MB association interceptors ...
protected void execute(DeploymentProcessorTarget processorTarget) { moduleDependencyProcessor.setGlobalModules(globalModules); isolationProcessor.setEarSubDeploymentsIsolated(earSubDeploymentsIsolated); ROOT_LOGGER.debug("Activating EE subsystem"); ...
protected void execute(DeploymentProcessorTarget processorTarget) { moduleDependencyProcessor.setGlobalModules(globalModules); isolationProcessor.setEarSubDeploymentsIsolated(earSubDeploymentsIsolated); ROOT_LOGGER.debug("Activating EE subsystem"); ...
public EJBBusinessMethod(MethodIntf view, String methodName, Class<?>... paramTypes) { if (methodName == null) { throw MESSAGES.methodeNameIsNull(); } this.methodName = methodName; this.methodParamTypes = paramTypes == null ? new Class<?>[0] : paramTypes; this.vie...
public EJBBusinessMethod(MethodIntf view, String methodName, Class<?>... paramTypes) { if (methodName == null) { throw MESSAGES.methodNameIsNull(); } this.methodName = methodName; this.methodParamTypes = paramTypes == null ? new Class<?>[0] : paramTypes; this.view...
public EntityBeanComponentCreateService(final ComponentConfiguration componentConfiguration, final ApplicationExceptions ejbJarConfiguration) { super(componentConfiguration, ejbJarConfiguration); final EntityBeanComponentDescription description = EntityBeanComponentDescription.class.cast(componentCo...
public EntityBeanComponentCreateService(final ComponentConfiguration componentConfiguration, final ApplicationExceptions ejbJarConfiguration) { super(componentConfiguration, ejbJarConfiguration); final EntityBeanComponentDescription description = EntityBeanComponentDescription.class.cast(componentCo...
public Object processInvocation(final InterceptorContext context) throws Exception { final EntityBeanComponent component = getComponent(context, EntityBeanComponent.class); final Object primaryKey = context.getPrivateData(EntityBeanComponent.PRIMARY_KEY_CONTEXT_KEY); if (primaryKey == null)...
public Object processInvocation(final InterceptorContext context) throws Exception { final EntityBeanComponent component = getComponent(context, EntityBeanComponent.class); final Object primaryKey = context.getPrivateData(EntityBeanComponent.PRIMARY_KEY_CONTEXT_KEY); if (primaryKey == null)...
public Object processInvocation(InterceptorContext context) throws Exception { final EntityBeanComponent component = getComponent(context, EntityBeanComponent.class); final EntityBeanComponentInstance instance = (EntityBeanComponentInstance) context.getPrivateData(ComponentInstance.class); ...
public Object processInvocation(InterceptorContext context) throws Exception { final EntityBeanComponent component = getComponent(context, EntityBeanComponent.class); final EntityBeanComponentInstance instance = (EntityBeanComponentInstance) context.getPrivateData(ComponentInstance.class); ...
public void configure(DeploymentPhaseContext context, ComponentDescription description, ComponentConfiguration configuration) throws DeploymentUnitProcessingException { viewClassLoader.setValue(Values.immediateValue(configuration.getModuleClassLoder())); } }); }
public void configure(DeploymentPhaseContext context, ComponentDescription description, ComponentConfiguration configuration) throws DeploymentUnitProcessingException { viewClassLoader.setValue(Values.immediateValue(configuration.getModuleClassLoader())); } }); }
public org.omg.CORBA.Object referenceForLocator(final EJBLocator<?> locator) { final EJBComponent ejbComponent = ejbComponentInjectedValue.getValue(); try { final String earApplicationName = ejbComponent.getEarApplicationName() == null ? "" : ejbComponent.getEarApplicationName(); ...
public org.omg.CORBA.Object referenceForLocator(final EJBLocator<?> locator) { final EJBComponent ejbComponent = ejbComponentInjectedValue.getValue(); try { final String earApplicationName = ejbComponent.getEarApplicationName() == null ? "" : ejbComponent.getEarApplicationName(); ...
public void listenerAdded(DeploymentRepository repository) { // get the initial available modules and send a message to the client final Map<DeploymentModuleIdentifier, ModuleDeployment> availableModules = this.deploymentRepository.getModules(); if (availableModules != null && !availableModu...
public void listenerAdded(DeploymentRepository repository) { // get the initial available modules and send a message to the client final Map<DeploymentModuleIdentifier, ModuleDeployment> availableModules = this.deploymentRepository.getModules(); if (availableModules != null && !availableModu...
int getRemoteDomainControllerPort(); /* * 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 re...
int getRemoteDomainControllerPort(); /* * 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 re...
static DomainServerMain.HostControllerCommunicationActivator createServerCommunicationActivator(final InetSocketAddress managementSocket, final String serverName, final String serverProcessName, /* * JBoss, Home of Professional Open Source. * Copyright 2011, Red Hat, Inc., and individual contributors * as indicated...
static DomainServerMain.HostControllerCommunicationActivator createServerCommunicationActivator(final InetSocketAddress managementSocket, final String serverName, final String serverProcessName, /* * JBoss, Home of Professional Open Source. * Copyright 2011, Red Hat, Inc., and individual contributors * as indicated...
private AttributeAnalysis(String javaName, AttributeMode mode, Method accessor, Method mutator) throws RMIIIOPViolationException { super(Util.javaToIDLName(javaName), javaName); this.mode = mode; this.cls = accessor.getReturnType(); this.accessor = accessor; this...
private AttributeAnalysis(String javaName, AttributeMode mode, Method accessor, Method mutator) throws RMIIIOPViolationException { super(Util.javaToIDLName(javaName), javaName); this.mode = mode; this.cls = accessor.getReturnType(); this.accessor = accessor; this...
String USE_MANAGEMENT_ENDPOINT = "use-management-endpoint"; /* * 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 fr...
String USE_MANAGEMENT_ENDPOINT = "use-management-endpoint"; /* * 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 fr...
private InetSocketAddress getServerSocketAddress(MailSessionServer server) throws StartException { final String ref = server.getOutgoingSocketBinding(); final OutboundSocketBinding binding = socketBindings.get(ref); if (ref == null) { throw MailMessages.MESSAGES.outboundSocketBin...
private InetSocketAddress getServerSocketAddress(MailSessionServer server) throws StartException { final String ref = server.getOutgoingSocketBinding(); final OutboundSocketBinding binding = socketBindings.get(ref); if (ref == null) { throw MailMessages.MESSAGES.outboundSocketBin...
public void execute(final OperationContext context, final ModelNode operation) throws OperationFailedException { // TODO should we make the runtime change by default, or require a header indicating that's valid? final String serverName = PathAddress.pathAddress(operation.re...
public void execute(final OperationContext context, final ModelNode operation) throws OperationFailedException { // TODO should we make the runtime change by default, or require a header indicating that's valid? final String serverName = PathAddress.pathAddress(operation.re...
String MAX_ATTEMPTS = "max-attempts"; /* * 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 r...
String MAX_ATTEMPTS = "max-attempts"; /* * 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 r...
private static ResourceBundle getResourceBundle(Locale locale) { if (locale == null) { locale = Locale.getDefault(); } return ResourceBundle.getBundle(RESOURCE_NAME, locale); } static ModelNode getConfigurationCommonDescription(final ModelNode node, final String type, fi...
private static ResourceBundle getResourceBundle(Locale locale) { if (locale == null) { locale = Locale.getDefault(); } return ResourceBundle.getBundle(RESOURCE_NAME, locale); } static ModelNode getConfigurationCommonDescription(final ModelNode node, final String type, fi...
public void unnexpectedError(final Throwable t) { ROOT_LOGGER.unnexpectedError(t); }
public void unnexpectedError(final Throwable t) { ROOT_LOGGER.unexpectedError(t); }
@Message(id = 12301, value = "A platform mbean resource does not have a writable model") /* * 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 c...
@Message(id = 12301, value = "A platform mbean resource does not have a writable model") /* * 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 c...
public ModelNode getModelDescription(Locale locale) { return PlatformMBeanDescriptions.getDumpThreadsDescripton(locale); }
public ModelNode getModelDescription(Locale locale) { return PlatformMBeanDescriptions.getDumpThreadsDescription(locale); }
public ModelNode getModelDescription(Locale locale) { return PlatformMBeanDescriptions.getGetThreadInfoDescripton(locale); }
public ModelNode getModelDescription(Locale locale) { return PlatformMBeanDescriptions.getGetThreadInfoDescription(locale); }
public ModelNode getModelDescription(Locale locale) { return PlatformMBeanDescriptions.getGetThreadInfosDescripton(locale); }
public ModelNode getModelDescription(Locale locale) { return PlatformMBeanDescriptions.getGetThreadInfosDescription(locale); }
public Method lookup(ClassReflectionIndex index) { Collection<Method> methods = index.getMethods(name, parameterTypes); if (methods.size() != 1) throw PojoMessages.MESSAGES.ambigousMatch(methods); return methods.iterator().next(); ...
public Method lookup(ClassReflectionIndex index) { Collection<Method> methods = index.getMethods(name, parameterTypes); if (methods.size() != 1) throw PojoMessages.MESSAGES.ambiguousMatch(methods); return methods.iterator().next(); ...
public void stop(StopContext context) { } Injector<Endpoint> getEnpointInjector() { return this.endpointInjectedValue; }
public void stop(StopContext context) { } Injector<Endpoint> getEndpointInjector() { return this.endpointInjectedValue; }
protected void performRuntime(OperationContext context, ModelNode operation, ModelNode model, ServiceVerificationHandler verificationHandler, List<ServiceController<?>> newControllers) throws OperationFailedException { final ModelNode fullModel = Resource.Tools....
protected void performRuntime(OperationContext context, ModelNode operation, ModelNode model, ServiceVerificationHandler verificationHandler, List<ServiceController<?>> newControllers) throws OperationFailedException { final ModelNode fullModel = Resource.Tools....
protected void performRuntime(OperationContext context, ModelNode operation, ModelNode model, ServiceVerificationHandler verificationHandler, List<ServiceController<?>> newControllers) throws OperationFailedException { final ModelNode fullModel = Resource.Tools.readModel(context.readResource(PathAddress.EMP...
protected void performRuntime(OperationContext context, ModelNode operation, ModelNode model, ServiceVerificationHandler verificationHandler, List<ServiceController<?>> newControllers) throws OperationFailedException { final ModelNode fullModel = Resource.Tools.readModel(context.readResource(PathAddress.EMP...
private RemoteOutboundConnectionWriteHandler() { super(RemoteOutboundConnnectionResourceDefinition.ATTRIBUTE_DEFINITIONS); }
private RemoteOutboundConnectionWriteHandler() { super(RemoteOutboundConnectionResourceDefinition.ATTRIBUTE_DEFINITIONS); }
public void initialize(ExtensionContext context) { // Register the remoting subsystem final SubsystemRegistration registration = context.registerSubsystem(SUBSYSTEM_NAME, 1, 0); registration.registerXMLElementWriter(RemotingSubsystem11Parser.INSTANCE); final ManagementResourceRegis...
public void initialize(ExtensionContext context) { // Register the remoting subsystem final SubsystemRegistration registration = context.registerSubsystem(SUBSYSTEM_NAME, 1, 0); registration.registerXMLElementWriter(RemotingSubsystem11Parser.INSTANCE); final ManagementResourceRegis...
public void start() { Console console = System.console(); if (console == null) { System.err.println("No console."); System.exit(1); } while (encDir == null || encDir.length() == 0 || !(encDir.endsWith("/") || encDir.endsWith("\\"))) { encDir = co...
public void start() { Console console = System.console(); if (console == null) { System.err.println("No console."); System.exit(1); } while (encDir == null || encDir.length() == 0 || !(encDir.endsWith("/") || encDir.endsWith("\\"))) { encDir = co...
private void handleDeployment(final DeploymentUnit deploymentUnit, final ModuleSpecification moduleSpec, final ModuleStructureSpec rootDeploymentSpecification) throws DeploymentUnitProcessingException { final Map<VirtualFile, ResourceRoot> resourceRoots = resourceRoots(deploymentUnit); moduleSpec.ad...
private void handleDeployment(final DeploymentUnit deploymentUnit, final ModuleSpecification moduleSpec, final ModuleStructureSpec rootDeploymentSpecification) throws DeploymentUnitProcessingException { final Map<VirtualFile, ResourceRoot> resourceRoots = resourceRoots(deploymentUnit); moduleSpec.ad...
private void executeInvalidOperation(ModelNode operation) throws IOException { try { executeOperation(createValidateOperation(operation)); Assert.fail("Should have failed on no required paramter included"); } catch (MgmtOperationException expected) { } }
private void executeInvalidOperation(ModelNode operation) throws IOException { try { executeOperation(createValidateOperation(operation)); Assert.fail("Should have failed on no required parameter included"); } catch (MgmtOperationException expected) { } }
public void addRemoveVirtualServer(@ArquillianResource Deployer deployer) throws Exception { if (! resolveHosts()) { log.info("Unable to resolve alternate server host name."); return; } addVirtualServer(); // deploy to virtual server deployer.deploy(...
public void addRemoveVirtualServer(@ArquillianResource Deployer deployer) throws Exception { if (! resolveHosts()) { log.info("Unable to resolve alternate server host name."); return; } addVirtualServer(); // deploy to virtual server deployer.deploy(...
private static <T> T lookup(String name, Class<T> expected) throws Exception { ModelControllerClient client = ModelControllerClient.Factory.create(InetAddress.getByName("127.0.0.1"), 9999, getCallbackHandler()); MBeanServerConnection mbeanServer = JMXConnectorFactory.connect(new JMXServiceURL("servi...
private static <T> T lookup(String name, Class<T> expected) throws Exception { ModelControllerClient client = ModelControllerClient.Factory.create(InetAddress.getByName("127.0.0.1"), 9999, getCallbackHandler()); MBeanServerConnection mbeanServer = JMXConnectorFactory.connect(new JMXServiceURL("servi...
public void testRegistryConfiguration() throws Throwable { ServiceController<?> controller=serviceContainer.getService( ConnectorServices.RA_REPOSISTORY_SERVICE); assertNotNull(controller); ResourceAdapterRepository repository=(ResourceAdapterRepository)controller.getValue(); assertNotNull(repos...
public void testRegistryConfiguration() throws Throwable { ServiceController<?> controller=serviceContainer.getService( ConnectorServices.RA_REPOSITORY_SERVICE); assertNotNull(controller); ResourceAdapterRepository repository=(ResourceAdapterRepository)controller.getValue(); assertNotNull(reposi...
public void testRegistryConfiguration() throws Throwable { ServiceController<?> controller=serviceContainer.getService( ConnectorServices.RA_REPOSISTORY_SERVICE); assertNotNull(controller); ResourceAdapterRepository repository=(ResourceAdapterRepository)controller.getValue(); assertNotNull(repos...
public void testRegistryConfiguration() throws Throwable { ServiceController<?> controller=serviceContainer.getService( ConnectorServices.RA_REPOSITORY_SERVICE); assertNotNull(controller); ResourceAdapterRepository repository=(ResourceAdapterRepository)controller.getValue(); assertNotNull(reposi...
private ModelNode getAddConnectorOp(Connector conn, String keyPEMFile, String certPEMFile, String keyStoreFile, String password) { ModelNode op = createOpNode("subsystem=web/connector=test-" + conn.getName() + "-connector", "add"); op.get("socket-binding").set("test-" + conn.getName()); op.g...
private ModelNode getAddConnectorOp(Connector conn, String keyPEMFile, String certPEMFile, String keyStoreFile, String password) { ModelNode op = createOpNode("subsystem=web/connector=test-" + conn.getName() + "-connector", "add"); op.get("socket-binding").set("test-" + conn.getName()); op.g...
private static final Map<String, ModelNode> defaults = new HashMap<String, ModelNode>(); static { defaults.put(Constants.DEVELOPMENT, new ModelNode().set(false)); defaults.put(Constants.DISABLED, new ModelNode().set(false)); defaults.put(Constants.KEEP_GENERATED, new ModelNode().set(tr...
private static final Map<String, ModelNode> defaults = new HashMap<String, ModelNode>(); static { defaults.put(Constants.DEVELOPMENT, new ModelNode().set(false)); defaults.put(Constants.DISABLED, new ModelNode().set(false)); defaults.put(Constants.KEEP_GENERATED, new ModelNode().set(tr...
@Message(id = 16075, value = "BeanDeploymentArchive with id %s not found in deployment") /* * 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 c...
@Message(id = 16075, value = "BeanDeploymentArchive with id %s not found in deployment") /* * 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 c...
private static final MarshallingConfiguration CONFIG; static { try { MARSHALLER_FACTORY = Marshalling.getMarshallerFactory("river", Module.getModuleFromDefaultLoader(ModuleIdentifier.fromString("org.jboss.marshalling.river")).getClassLoader()); } catch (ModuleLoadException e) { ...
private static final MarshallingConfiguration CONFIG; static { try { MARSHALLER_FACTORY = Marshalling.getMarshallerFactory("river", Module.getModuleFromCurrentLoader(ModuleIdentifier.fromString("org.jboss.marshalling.river")).getClassLoader()); } catch (ModuleLoadException e) { ...
private void updateLdapConnectionService(final OperationContext context, final ModelNode operation, final ModelNode model) throws OperationFailedException { PathAddress address = PathAddress.pathAddress(operation.require(OP_ADDR)); String name = address.getLastElement().getValue(); ServiceNa...
private void updateLdapConnectionService(final OperationContext context, final ModelNode operation, final ModelNode model) throws OperationFailedException { PathAddress address = PathAddress.pathAddress(operation.require(OP_ADDR)); String name = address.getLastElement().getValue(); ServiceNa...
public void testInvalidFormat() throws Exception { final CSVFormat invalidFormat = CSVFormat.DEFAULT.withDelimiter(CR); new CSVParser((Reader) null, invalidFormat); }
public void testInvalidFormat() throws Exception { final CSVFormat invalidFormat = CSVFormat.DEFAULT.withDelimiter(CR); new CSVParser((Reader) null, invalidFormat).close(); }
public void testInvalidFormat() throws Exception { final CSVFormat invalidFormat = CSVFormat.DEFAULT.withDelimiter(CR); new CSVPrinter(null, invalidFormat); }
public void testInvalidFormat() throws Exception { final CSVFormat invalidFormat = CSVFormat.DEFAULT.withDelimiter(CR); new CSVPrinter(null, invalidFormat).close(); }
private static String formatName(String name) { for(int i = 0; i < name.length(); ++i) { char ch = name.charAt(i); if(ch == ':' || ch == '/') { // now escape the quotes StringBuilder builder = new StringBuilder(); builder.append('"'); ...
private static String formatName(String name) { for(int i = 0; i < name.length(); ++i) { char ch = name.charAt(i); if(ch == ':' || ch == '/' || ch == '=') { // now escape the quotes StringBuilder builder = new StringBuilder(); builder.a...
public enum Interfaces { INCLUDE, EXCLUDE; }
public enum Interfaces { INCLUDE, EXCLUDE }
public static Method getMatchingAccessibleMethod(Class<?> cls, String methodName, Class<?>... parameterTypes) { try { Method method = cls.getMethod(methodName, parameterTypes); MemberUtils.setAccessibleWorkaround(method); return method; } catch (NoSuch...
public static Method getMatchingAccessibleMethod(Class<?> cls, String methodName, Class<?>... parameterTypes) { try { Method method = cls.getMethod(methodName, parameterTypes); MemberUtils.setAccessibleWorkaround(method); return method; } catch (NoSuch...
public void testSkipsPK00Prefix() throws Exception { final File input = getFile("COMPRESS-208.zip"); InputStream is = new FileInputStream(input); ArrayList al = new ArrayList(); al.add("test1.xml"); al.add("test2.xml"); try { checkArchiveContent(new ZipArc...
public void testSkipsPK00Prefix() throws Exception { final File input = getFile("COMPRESS-208.zip"); InputStream is = new FileInputStream(input); ArrayList<String> al = new ArrayList<String>(); al.add("test1.xml"); al.add("test2.xml"); try { checkArchiveCo...
public Message<?> postProcessMessage(Message<?> message) { SimpMessageHeaderAccessor headers = SimpMessageHeaderAccessor.wrap(message); headers.setSessionId(this.sessionId); return MessageBuilder.withPayloadAndHeaders(message.getPayload(), headers).build(); } }
public Message<?> postProcessMessage(Message<?> message) { SimpMessageHeaderAccessor headers = SimpMessageHeaderAccessor.wrap(message); headers.setSessionId(this.sessionId); return MessageBuilder.withPayload(message.getPayload()).setHeaders(headers).build(); } }
public Message<?> postProcessMessage(Message<?> message) { SimpMessageHeaderAccessor headers = SimpMessageHeaderAccessor.wrap(message); headers.setSessionId(this.sessionId); headers.setSubscriptionId(this.subscriptionId); headers.setMessageTypeIfNotSet(SimpMessageType.MESSAGE); return MessageBuilder.wi...
public Message<?> postProcessMessage(Message<?> message) { SimpMessageHeaderAccessor headers = SimpMessageHeaderAccessor.wrap(message); headers.setSessionId(this.sessionId); headers.setSubscriptionId(this.subscriptionId); headers.setMessageTypeIfNotSet(SimpMessageType.MESSAGE); return MessageBuilder.wi...
private void handleMessageInternal(Message<?> message, Map<MappingInfo, HandlerMethod> handlerMethods) { if (logger.isTraceEnabled()) { logger.trace("Message " + message); } SimpMessageHeaderAccessor headers = SimpMessageHeaderAccessor.wrap(message); String lookupPath = getLookupPath(headers.getDestinatio...
private void handleMessageInternal(Message<?> message, Map<MappingInfo, HandlerMethod> handlerMethods) { if (logger.isTraceEnabled()) { logger.trace("Message " + message); } SimpMessageHeaderAccessor headers = SimpMessageHeaderAccessor.wrap(message); String lookupPath = getLookupPath(headers.getDestinatio...
public void handleMessage(Message<?> message) throws MessagingException { SimpMessageHeaderAccessor headers = SimpMessageHeaderAccessor.wrap(message); SimpMessageType messageType = headers.getMessageType(); String destination = headers.getDestination(); if (!SimpMessageType.MESSAGE.equals(messageType)) { ...
public void handleMessage(Message<?> message) throws MessagingException { SimpMessageHeaderAccessor headers = SimpMessageHeaderAccessor.wrap(message); SimpMessageType messageType = headers.getMessageType(); String destination = headers.getDestination(); if (!SimpMessageType.MESSAGE.equals(messageType)) { ...
protected Message<String> createConnectMessage(String sessionId) { SimpMessageHeaderAccessor headers = SimpMessageHeaderAccessor.create(SimpMessageType.CONNECT); headers.setSessionId(sessionId); return MessageBuilder.withPayloadAndHeaders("", headers).build(); }
protected Message<String> createConnectMessage(String sessionId) { SimpMessageHeaderAccessor headers = SimpMessageHeaderAccessor.create(SimpMessageType.CONNECT); headers.setSessionId(sessionId); return MessageBuilder.withPayload("").setHeaders(headers).build(); }
public void startChannels() throws IOException, URISyntaxException { ProtocolChannelClient.Configuration<ManagementChannel> configuration = new ProtocolChannelClient.Configuration<ManagementChannel>(); configuration.setEndpointName(ENDPOINT_NAME); configuration.setUriScheme(URI_SCHEME); ...
public void startChannels() throws IOException, URISyntaxException { ProtocolChannelClient.Configuration<ManagementChannel> configuration = new ProtocolChannelClient.Configuration<ManagementChannel>(); configuration.setEndpointName(ENDPOINT_NAME); configuration.setUriScheme(URI_SCHEME); ...
public void startChannels() throws IOException, URISyntaxException { ProtocolChannelClient.Configuration<ManagementChannel> configuration = new ProtocolChannelClient.Configuration<ManagementChannel>(); configuration.setEndpointName(ENDPOINT_NAME); configuration.setUriScheme(URI_SCHEME); ...
public void startChannels() throws IOException, URISyntaxException { ProtocolChannelClient.Configuration<ManagementChannel> configuration = new ProtocolChannelClient.Configuration<ManagementChannel>(); configuration.setEndpointName(ENDPOINT_NAME); configuration.setUriScheme(URI_SCHEME); ...
public synchronized void start(StartContext context) throws StartException { ProtocolChannelClient<ManagementChannel> client; try { ProtocolChannelClient.Configuration<ManagementChannel> configuration = new ProtocolChannelClient.Configuration<ManagementChannel>(); configurat...
public synchronized void start(StartContext context) throws StartException { ProtocolChannelClient<ManagementChannel> client; try { ProtocolChannelClient.Configuration<ManagementChannel> configuration = new ProtocolChannelClient.Configuration<ManagementChannel>(); configurat...
public interface ScatterGatherBackingStore extends Closeable { /* * 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 Yo...
public interface ScatterGatherBackingStore extends Closeable { /* * 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 Yo...
private void closeEntry() throws IOException { if (closed) { throw new IOException("The stream is closed"); } if (current == null) { return; } // Ensure all entry bytes are read if (bytesReadFromStream <= current.getCompressedSize() ...
private void closeEntry() throws IOException { if (closed) { throw new IOException("The stream is closed"); } if (current == null) { return; } // Ensure all entry bytes are read if (bytesReadFromStream <= current.getCompressedSize() ...
protected DsSecurity parseDsSecurity(XMLStreamReader reader) throws XMLStreamException, ParserException, ValidateException { String userName = null; String password = null; String securityDomain = null; Extension reauthPlugin = null; while (reader.hasNext()) { ...
protected DsSecurity parseDsSecurity(XMLStreamReader reader) throws XMLStreamException, ParserException, ValidateException { String userName = null; String password = null; String securityDomain = null; Extension reauthPlugin = null; while (reader.hasNext()) { ...
public void initialize(ExtensionContext context) { final SubsystemRegistration subsystem = context.registerSubsystem(SUBSYSTEM_NAME); final ManagementResourceRegistration registration = subsystem.registerSubsystemModel(OSGiSubsystemProviders.SUBSYSTEM); registration.registerOperationHandler(...
public void initialize(ExtensionContext context) { final SubsystemRegistration subsystem = context.registerSubsystem(SUBSYSTEM_NAME); final ManagementResourceRegistration registration = subsystem.registerSubsystemModel(OSGiSubsystemProviders.SUBSYSTEM); registration.registerOperationHandler(...
package org.apache.commons.math.analysis.integration; /* * 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 A...
package org.apache.commons.math.analysis.integration; /* * 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 A...
public MathParseException(String wrong, int position, Class type) { super(null, null, LocalizedFormats.CANNOT_PARSE_AS_TYPE, wrong, new Integer(position), type.getName()); }
public MathParseException(String wrong, int position, Class<?> type) { super(null, null, LocalizedFormats.CANNOT_PARSE_AS_TYPE, wrong, new Integer(position), type.getName()); }
protected Boolean fromAnnotation(final AnnotationInstance annotationInstance) { return true; } }
protected Boolean fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { return true; } }
protected String[] fromAnnotation(final AnnotationInstance annotationInstance) { final Type[] classes = annotationInstance.value().asClassArray(); final String[] ret = new String[classes.length]; for(int i = 0; i < classes.length; ++i) { ret[i] = classes[i].name().toString(); ...
protected String[] fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { final Type[] classes = annotationInstance.value().asClassArray(); final String[] ret = new String[classes.length]; for(int i = 0; i < classes.length; ++i) { ret[i] = class...
protected AccessTimeoutDetails fromAnnotation(final AnnotationInstance annotationInstance) { final long timeout = annotationInstance.value().asLong(); AnnotationValue unitAnnVal = annotationInstance.value("unit"); final TimeUnit unit = unitAnnVal != null ? TimeUnit.valueOf(unitAnnVal.asEnum(...
protected AccessTimeoutDetails fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { final long timeout = annotationInstance.value().asLong(); AnnotationValue unitAnnVal = annotationInstance.value("unit"); final TimeUnit unit = unitAnnVal != null ? TimeUnit...
protected CacheInfo fromAnnotation(AnnotationInstance annotationInstance) { String value = annotationInstance.value().asString(); return new CacheInfo(value); } }
protected CacheInfo fromAnnotation(AnnotationInstance annotationInstance, boolean replacement) { String value = annotationInstance.value().asString(); return new CacheInfo(value); } }
protected ClusteringInfo fromAnnotation(AnnotationInstance annotationInstance) { return new ClusteringInfo(); } }
protected ClusteringInfo fromAnnotation(AnnotationInstance annotationInstance, boolean replacement) { return new ClusteringInfo(); } }
protected ConcurrencyManagementType fromAnnotation(final AnnotationInstance annotationInstance) { final AnnotationValue value = annotationInstance.value(); if(value == null) { return ConcurrencyManagementType.CONTAINER; } return ConcurrencyManagementType.valueOf(value.asE...
protected ConcurrencyManagementType fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { final AnnotationValue value = annotationInstance.value(); if(value == null) { return ConcurrencyManagementType.CONTAINER; } return ConcurrencyManag...
protected String[] fromAnnotation(final AnnotationInstance annotationInstance) { return annotationInstance.value().asStringArray(); } }
protected String[] fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { return annotationInstance.value().asStringArray(); } }
protected Boolean fromAnnotation(final AnnotationInstance annotationInstance) { return annotationInstance.value().asBoolean(); } }
protected Boolean fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { return annotationInstance.value().asBoolean(); } }
protected String fromAnnotation(final AnnotationInstance annotationInstance) { AnnotationValue value = annotationInstance.value(); if (value == null) { return null; } return value.asString(); } }
protected String fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { AnnotationValue value = annotationInstance.value(); if (value == null) { return null; } return value.asString(); } }
protected String fromAnnotation(final AnnotationInstance annotationInstance) { AnnotationValue value = annotationInstance.value(); return value.asClass().toString(); } }
protected String fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { AnnotationValue value = annotationInstance.value(); return value.asClass().toString(); } }
protected LockType fromAnnotation(final AnnotationInstance annotationInstance) { AnnotationValue value = annotationInstance.value(); if(value == null) { return LockType.WRITE; } return LockType.valueOf(annotationInstance.value().asEnum()); } }
protected LockType fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { AnnotationValue value = annotationInstance.value(); if(value == null) { return LockType.WRITE; } return LockType.valueOf(annotationInstance.value().asEnum()); }...
protected String fromAnnotation(final AnnotationInstance annotationInstance) { return annotationInstance.value().asString(); } }
protected String fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { return annotationInstance.value().asString(); } }
protected Boolean fromAnnotation(final AnnotationInstance annotationInstance) { AnnotationValue value = annotationInstance.value("retainIfException"); if(value == null) { return false; } return value.asBoolean(); } }
protected Boolean fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { AnnotationValue value = annotationInstance.value("retainIfException"); if(value == null) { return false; } return value.asBoolean(); } }
protected StatefulTimeoutInfo fromAnnotation(final AnnotationInstance annotationInstance) { final long value = annotationInstance.value().asLong(); final AnnotationValue unitValue = annotationInstance.value("unit"); final TimeUnit unit; if (unitValue != null) { unit = Tim...
protected StatefulTimeoutInfo fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { final long value = annotationInstance.value().asLong(); final AnnotationValue unitValue = annotationInstance.value("unit"); final TimeUnit unit; if (unitValue != nul...
protected TransactionAttributeType fromAnnotation(final AnnotationInstance annotationInstance) { final AnnotationValue value = annotationInstance.value(); if(value == null) { return TransactionAttributeType.REQUIRED; } return TransactionAttributeType.valueOf(value.asEnum...
protected TransactionAttributeType fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { final AnnotationValue value = annotationInstance.value(); if(value == null) { return TransactionAttributeType.REQUIRED; } return TransactionAttribu...
protected TransactionManagementType fromAnnotation(final AnnotationInstance annotationInstance) { final AnnotationValue value = annotationInstance.value(); if(value == null) { return TransactionManagementType.CONTAINER; } return TransactionManagementType.valueOf(value.asE...
protected TransactionManagementType fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { final AnnotationValue value = annotationInstance.value(); if(value == null) { return TransactionManagementType.CONTAINER; } return TransactionManag...
protected Integer fromAnnotation(final AnnotationInstance annotationInstance) { final long timeout = annotationInstance.value().asLong(); AnnotationValue unitAnnVal = annotationInstance.value("unit"); final TimeUnit unit = unitAnnVal != null ? TimeUnit.valueOf(unitAnnVal.asEnum()) : TimeUnit...
protected Integer fromAnnotation(final AnnotationInstance annotationInstance, final boolean replacement) { final long timeout = annotationInstance.value().asLong(); AnnotationValue unitAnnVal = annotationInstance.value("unit"); final TimeUnit unit = unitAnnVal != null ? TimeUnit.valueOf(unit...
public static Archive<?> deployment() { final Archive<?> deployment = ShrinkWrap.create(JavaArchive.class, "ejb3mdb.jar") .addPackage(ReplyingMDB.class.getPackage()) .addClass(CreateQueueSetupTask.class); return deployment; }
public static Archive<?> deployment() { final Archive<?> deployment = ShrinkWrap.create(JavaArchive.class, "ejb3mdb.jar") .addClasses(ReplyingMDB.class,JMSMessagingUtil.class) .addClass(CreateQueueSetupTask.class); return deployment; }
public void handleRequest(final HttpServerExchange exchange) throws Exception { final SecurityContext securityContext = exchange.getAttachment(SecurityContext.ATTACHMENT_KEY); final Subject useSubject; if (securityContext != null) { final Account account = securityContext.getAuth...
public void handleRequest(final HttpServerExchange exchange) throws Exception { final SecurityContext securityContext = exchange.getSecurityContext(); final Subject useSubject; if (securityContext != null) { final Account account = securityContext.getAuthenticatedAccount(); ...
private void validateRequest(CommandContext ctx, ModelNode request) throws CommandFormatException { final ModelControllerClient client = ctx.getModelControllerClient(); if(client == null) { throw new CommandFormatException("No connection to the controller."); } final Se...
private void validateRequest(CommandContext ctx, ModelNode request) throws CommandFormatException { final ModelControllerClient client = ctx.getModelControllerClient(); if(client == null) { throw new CommandFormatException("No connection to the controller."); } final Se...
public static final AttributeDefinition[] ATTRIBUTE_DEFINITIONS = { KeystoreAttributes.KEYSTORE_PASSWORD, KeystoreAttributes.KEYSTORE_PATH, KeystoreAttributes.KEYSTORE_RELATIVE_TO };
public static final AttributeDefinition[] ATTRIBUTE_DEFINITIONS = { KeystoreAttributes.KEYSTORE_PASSWORD, KeystoreAttributes.KEYSTORE_PATH, KeystoreAttributes.KEYSTORE_RELATIVE_TO, KeystoreAttributes.KEYSTORE_PROVIDER };
protected String decodeText(final String text) throws DecoderException, UnsupportedEncodingException { if (text == null) { return null; } if ((!text.startsWith(PREFIX)) || (!text.endsWith(POSTFIX))) { throw new DecoderException("RFC 1522 violation: malforme...
protected String decodeText(final String text) throws DecoderException, UnsupportedEncodingException { if (text == null) { return null; } if ((!text.startsWith(PREFIX)) || (!text.endsWith(POSTFIX))) { throw new DecoderException("RFC 1522 violation: malforme...
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); if (deploymentUnit.getParent() != null) { return; } final ServiceTarget serviceTarget = phaseContext...
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); if (deploymentUnit.getParent() != null) { return; } final ServiceTarget serviceTarget = phaseContext...
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); if (isEarDeployment(deploymentUnit)) { return; } final ServiceTarget serviceTarget = phaseContext.get...
public void deploy(DeploymentPhaseContext phaseContext) throws DeploymentUnitProcessingException { final DeploymentUnit deploymentUnit = phaseContext.getDeploymentUnit(); if (isEarDeployment(deploymentUnit)) { return; } final ServiceTarget serviceTarget = phaseContext.get...
public interface BaseMultivariateSimpleBoundsOptimizer<FUNC extends MultivariateFunction> /* * 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 l...
public interface BaseMultivariateSimpleBoundsOptimizer<FUNC extends MultivariateFunction> /* * 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 l...
private static void copyProperties(Object source, Object target, Class<?> editable, String... ignoreProperties) throws BeansException { Assert.notNull(source, "Source must not be null"); Assert.notNull(target, "Target must not be null"); Class<?> actualEditable = target.getClass(); if (editable != null) {...
private static void copyProperties(Object source, Object target, Class<?> editable, String... ignoreProperties) throws BeansException { Assert.notNull(source, "Source must not be null"); Assert.notNull(target, "Target must not be null"); Class<?> actualEditable = target.getClass(); if (editable != null) {...
public synchronized void delete() { listField.removeFirstOccurrence(Integer.valueOf(random.nextInt(N))); }
public synchronized void delete() { listField.remove(Integer.valueOf(random.nextInt(N))); }
public EJBContainer createEJBContainer(Map<?, ?> properties) throws EJBException { //setSystemProperty("java.util.logging.manager", "org.jboss.logmanager.LogManager"); // see EjbDependencyDeploymentUnitProcessor setSystemProperty("org.jboss.as.ejb3.EMBEDDED", "true"); String jbossH...
public EJBContainer createEJBContainer(Map<?, ?> properties) throws EJBException { //setSystemProperty("java.util.logging.manager", "org.jboss.logmanager.LogManager"); // see EjbDependencyDeploymentUnitProcessor setSystemProperty("org.jboss.as.ejb3.EMBEDDED", "true"); String jbossH...
public void handleMessageEncodedUserName() { String userName = "http://joe.openid.example.org/"; this.registry.registerSessionId(userName, "openid123"); String destination = "/user/" + StringUtils.replace(userName, "/", "%2F") + "/queue/foo"; Message<?> message = createMessage(SimpMessageType.MESSAGE, this.us...
public void handleMessageEncodedUserName() { String userName = "http://joe.openid.example.org/"; this.registry.registerSessionId(userName, "openid123"); String destination = "/user/" + StringUtils.replace(userName, "/", "%2F") + "/queue/foo"; Message<?> message = createMessage(SimpMessageType.MESSAGE, this.us...
public static void parseJvm(final XMLExtendedStreamReader reader, final ModelNode parentAddress, final Namespace expectedNs, final List<ModelNode> updates, final Set<String> jvmNames, final boolean server) throws XMLStreamException { // Handle attributes final List<ModelNode> attrUpdate...
public static void parseJvm(final XMLExtendedStreamReader reader, final ModelNode parentAddress, final Namespace expectedNs, final List<ModelNode> updates, final Set<String> jvmNames, final boolean server) throws XMLStreamException { // Handle attributes final List<ModelNode> attrUpdate...
public List<Endpoint> publish(ServiceTarget target, WSEndpointDeploymentUnit unit) throws Exception { List<DeploymentAspect> aspects = DeploymentAspectsProvider.getSortedDeploymentAspects(); ClassLoader origClassLoader = SecurityActions.getContextClassLoader(); Deployment dep = null; ...
public List<Endpoint> publish(ServiceTarget target, WSEndpointDeploymentUnit unit) throws Exception { List<DeploymentAspect> aspects = DeploymentAspectsProvider.getSortedDeploymentAspects(); ClassLoader origClassLoader = SecurityActions.getContextClassLoader(); Deployment dep = null; ...
public void getType() { OptionMap options = OptionMap.builder().getMap(); assertSame(Connector.Type.AJP, new UndertowConnector(new AjpListenerService("", "", options)).getType()); assertSame(Connector.Type.HTTP, new UndertowConnector(new HttpListenerService("", "", options, false)).getType()...
public void getType() { OptionMap options = OptionMap.builder().getMap(); assertSame(Connector.Type.AJP, new UndertowConnector(new AjpListenerService("", "", options)).getType()); assertSame(Connector.Type.HTTP, new UndertowConnector(new HttpListenerService("", "", options, false, false)).ge...
public HttpsListenerService(final String name, String serverName, OptionMap listenerOptions) { super(name, serverName, listenerOptions, false); }
public HttpsListenerService(final String name, String serverName, OptionMap listenerOptions) { super(name, serverName, listenerOptions, false, false); }
private static <T extends CommandInterceptor> T getFirstInterceptorWhichExtends(List<CommandInterceptor> interceptors, Class<T> interceptorClass) { for (CommandInterceptor interceptor : interceptors) { boolean is...
private static <T extends CommandInterceptor> T getFirstInterceptorWhichExtends(List<CommandInterceptor> interceptors, Class<T> interceptorClass) { for (CommandInterceptor interceptor : interceptors) { boolean is...
public void serviceFailed(ServiceController<?> serviceController, StartException reason) { log.errorf(reason, "Service [%s] failed.", serviceController.getName()); } }); final ServiceActivatorContext serviceActivatorContext = new ServiceActivatorContextImpl(batch...
public void serviceFailed(ServiceController<?> serviceController, StartException reason) { log.errorf(reason, "Service [%s] failed.", serviceController.getName()); } }); final ServiceActivatorContext serviceActivatorContext = new ServiceActivatorContextImpl(batch...
protected void resolvePluggableExpression(ModelNode node) { String expression = node.asString(); if (expression.length() > 3) { expression = expression.substring(2, expression.length() -2); if ( vaultReader.isVaultFormat(expression)) { node.set(vaultReader.ret...
protected void resolvePluggableExpression(ModelNode node) { String expression = node.asString(); if (expression.length() > 3) { expression = expression.substring(2, expression.length() -2); if (vaultReader != null && vaultReader.isVaultFormat(expression)) { no...
public void testRoundTripNames(){ checkName(""); checkName("The quick brown fox\n"); checkName("\177"); // checkName("\0"); // does not work, because NUL is ignored // COMPRESS-114 checkName("0302-0601-3±±±F06±W220±ZB±LALALA±±±±±±±±±±CAN±±DC±±±04±060302±MOE.model"); ...
public void testRoundTripNames(){ checkName(""); checkName("The quick brown fox\n"); checkName("\177"); // checkName("\0"); // does not work, because NUL is ignored // COMPRESS-114 checkName("0302-0601-3\u00b1\u00b1\u00b1F06\u00b1W220\u00b1ZB\u00b1LALALA\u00b1\u00b1\u...
public static void checkFailedTransformedBootOperations(ModelTestKernelServices<?> mainServices, ModelVersion modelVersion, List<ModelNode> operations, FailedOperationTransformationConfig config) throws OperationFailedException { for (ModelNode op : operations) { ModelTestUtils.checkOutcome(main...
public static void checkFailedTransformedBootOperations(ModelTestKernelServices<?> mainServices, ModelVersion modelVersion, List<ModelNode> operations, FailedOperationTransformationConfig config) throws OperationFailedException { for (ModelNode op : operations) { ModelTestUtils.checkOutcome(main...
public synchronized void stop(StopContext context) { final LocalEjbReceiver localEjbReceiver = this.localEjbReceiverInjectedValue.getOptionalValue(); if (localEjbReceiver != null) { localEjbReceiver.stop(context); logger.debugf("Removed a local EJB receiver from descriptor ba...
public synchronized void stop(StopContext context) { final LocalEjbReceiver localEjbReceiver = this.localEjbReceiverInjectedValue.getOptionalValue(); if (localEjbReceiver != null) { this.ejbClientContext.unregisterEJBReceiver(localEjbReceiver); logger.debugf("Removed a local ...
private void processField(final EEModuleDescription eeModuleDescription, final EJBResourceWrapper annotation, final FieldInfo fieldInfo) { final String fieldName = fieldInfo.name(); final String injectionType = isEmpty(annotation.beanInterface()) || annotation.beanInterface().equals(Object.class.get...
private void processField(final EEModuleDescription eeModuleDescription, final EJBResourceWrapper annotation, final FieldInfo fieldInfo) { final String fieldName = fieldInfo.name(); final String injectionType = isEmpty(annotation.beanInterface()) || annotation.beanInterface().equals(Object.class.get...