Skip to content

Instantly share code, notes, and snippets.

View anpieber's full-sized avatar

Andreas Pieber anpieber

  • Schmutterer+Partner Information Technology GmbH
  • Austria, Vienna
View GitHub Profile
karaf@root> admin:create node2
karaf@root> admin:start node2
karaf@root> admin:connect node2
Connecting to host localhost on port 8102
Connected
__ __ ____
/ //_/____ __________ _/ __/
/ ,< / __ `/ ___/ __ `/ /_
/ /| |/ /_/ / / / /_/ / __/
/_/ |_|\__,_/_/ \__,_/_/
public OverviewPage createPage( PageParameters params )
{
PageFactory<Page>[] pageSources = PageFinder.findPages( m_context, "departmentstore", "about" );
Class pageClass;
if( pageSources.length == 0 )
{
pageClass = null;
}
else
{
<wsdl:definitions name="PortReceiverService" targetNamespace="http://ws.ports.openengsb.org/">
<wsdl:portType name="PortReceiver"> </wsdl:portType>
<wsdl:binding name="PortReceiverServiceSoapBinding" type="tns:PortReceiver">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
</wsdl:binding>
<wsdl:service name="PortReceiverService">
<wsdl:port binding="tns:PortReceiverServiceSoapBinding" name="PortReceiverPort">
<soap:address location="http://localhost:8090/ws/receiver/"/>
</wsdl:port>
</wsdl:service>
12:37:24,450 | DEBUG | rint Extender: 1 | JAXBDataBinding | .apache.cxf.jaxb.JAXBDataBinding 296 | - - | Created JAXBContext "bundleresource://84.fwk605324898/com/sun/xml/bind/v2/runtime/JAXBContextImpl.class Build-Id: 2.2.2
Classes known to this context:
[B
boolean
byte
char
com.sun.xml.bind.api.CompositeStructure
double
float
int
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:osgi="http://www.springframework.org/schema/osgi"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context="http://www.springframework.org/schema/context"
xmlns:osgix="http://www.springframework.org/schema/osgi-compendium" xmlns:wicket="http://www.ops4j.org/schema/wicket"
xsi:schemaLocation="http://www.springframework.org/schema/osgi http://www.springframework.org/schema/osgi/spring-osgi.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd
http://www.springframework.org/schema/osgi-compendium http://www.springframework.org/schema/osgi-compendium/spring-osgi-compendium.xsd
http://www.ops4j.org/schema/wicket http://www.ops4j.org/schema/wicket/wicket.xsd">
@anpieber
anpieber / gist:1050835
Created June 28, 2011 10:00
injection
diff --git a/service/src/main/java/org/ops4j/pax/wicket/api/PaxWicketApplicationFactory.java b/service/src/main/java/org/ops4j/pax/wicket/api/PaxWicketApplicationFactory.java
index d724980..6b9a800 100644
--- a/service/src/main/java/org/ops4j/pax/wicket/api/PaxWicketApplicationFactory.java
+++ b/service/src/main/java/org/ops4j/pax/wicket/api/PaxWicketApplicationFactory.java
@@ -97,6 +97,8 @@ public final class PaxWicketApplicationFactory implements IWebApplicationFactory
private ServiceRegistration bdciRegistration;
private BundleDelegatingComponentInstanciationListener bdci;
+ private final String defaultInjectionSource;
+
@anpieber
anpieber / gist:1058147
Created July 1, 2011 09:14
scanbundle
Bundle bundleToScan = bundleContext.getBundle();
Enumeration<?> findEntries = bundleToScan.findEntries("", "*.class", true);
while (findEntries.hasMoreElements()) {
URL object = (URL) findEntries.nextElement();
String className = object.getFile().substring(1, object.getFile().length() - 6).replaceAll("/", ".");
Class<?> candidateClass = bundleToScan.loadClass(className);
if (!Page.class.isAssignableFrom(candidateClass)) {
continue;
}
Class<? extends Page> pageClass = (Class<? extends Page>) candidateClass;
diff --git a/shell/osgi/src/main/java/org/apache/karaf/shell/osgi/Util.java b/shell/osgi/src/main/java/org/apache/karaf/shell/osgi/Util.java
index 0a4f5d8..5bd2166 100644
--- a/shell/osgi/src/main/java/org/apache/karaf/shell/osgi/Util.java
+++ b/shell/osgi/src/main/java/org/apache/karaf/shell/osgi/Util.java
@@ -19,6 +19,9 @@
package org.apache.karaf.shell.osgi;
import java.io.IOException;
+import java.net.MalformedURLException;
+import java.net.URI;
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0" xmlns:wicket="http://www.ops4j.org/schema/wicket">
<wicket:application id="applicationId" class="org.ops4j.pax.wicket.samples.blueprint.simple.internal.WicketApplication"
applicationName="blueprint.simple.paxwicket" mountPoint="blueprint/simple/paxwicket" />
</blueprint>
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0" >
<service interface="org.apache.wicket.protocol.http.IWebApplicationFactory" >
<service-properties>
<entry key="pax.wicket.applicationname" value="blueprint.simple.default" />
<entry key="pax.wicket.mountpoint" value="blueprint/simple/default" />
</service-properties>
<bean class="org.ops4j.pax.wicket.util.SimpleWebApplicationFactory" >
<property name="wicketApplication" value="org.ops4j.pax.wicket.samples.blueprint.simple.internal.WicketApplication" />
</bean>