Examples of ClassLoaderResolver


Examples of com.atilika.kuromoji.ClassLoaderResolver

        dictionary.loadPosVector(resolver.resolve(PART_OF_SPEECH_FILENAME));
        return dictionary;
  }

    public static UnknownDictionary newInstance() throws IOException, ClassNotFoundException {
        return newInstance(new ClassLoaderResolver(UnknownDictionary.class));
    }
View Full Code Here

Examples of org.apache.cxf.resource.ClassLoaderResolver

                }
            });
        super.setExtension(bundleClassLoader, ClassLoader.class);
        // Setup the resource resolver with the bundle classloader
        ResourceManager rm = super.getExtension(ResourceManager.class);
        rm.addResourceResolver(new ClassLoaderResolver(bundleClassLoader));
        super.setExtension(c, BundleContext.class);
    }
View Full Code Here

Examples of org.datanucleus.ClassLoaderResolver

    protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException
    {
        try
        {
            String className = getClassName(req);
            ClassLoaderResolver clr = api.getClassLoaderResolver();
            AbstractClassMetaData cmd = api.getMetaDataManager().getMetaDataForEntityName(className);
            try
            {
                if (cmd == null)
                {
View Full Code Here

Examples of org.datanucleus.ClassLoaderResolver

    }

    protected void doHead(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException
    {
        String className = getClassName(req);
        ClassLoaderResolver clr = api.getClassLoaderResolver();
        AbstractClassMetaData cmd = api.getMetaDataManager().getMetaDataForEntityName(className);
        try
        {
            if (cmd == null)
            {
View Full Code Here

Examples of org.datanucleus.ClassLoaderResolver

    {
        try
        {
            String className = getClassName(req);

            ClassLoaderResolver clr = api.getClassLoaderResolver();
            AbstractClassMetaData cmd = api.getMetaDataManager().getMetaDataForEntityName(className);
            try
            {
                if (cmd == null)
                {
View Full Code Here

Examples of org.jpox.ClassLoaderResolver

        {
            throw new IllegalArgumentException(LOCALISER.msg("Query.NamedQueryNotFound", queryName));
        }

        // Find the Query for the specified class
        ClassLoaderResolver clr = om.getClassLoaderResolver();
        QueryMetaData qmd = om.getMetaDataManager().getMetaDataForQuery(null, clr, queryName);
        if (qmd == null)
        {
            throw new IllegalArgumentException(LOCALISER.msg("Query.NamedQueryNotFound", queryName));
        }
View Full Code Here

Examples of org.jpox.ClassLoaderResolver

     */
    @SuppressWarnings("unchecked")
    private void invokeCallback(final Object pc, final Class callbackClass)
    {
        final ObjectManager om = ((AbstractPersistenceManager) ((PersistenceCapable) pc).jdoGetPersistenceManager()).getObjectManager();
        final ClassLoaderResolver clr = om.getClassLoaderResolver();

        AbstractClassMetaData acmd = om.getOMFContext().getMetaDataManager().getMetaDataForClass(pc.getClass(), clr);

        try
        {
            if (!acmd.isExcludeDefaultListeners())
            {
                // Global listeners for all classes
                List<EventListenerMetaData> listenerMetaData = om.getMetaDataManager().getListeners();
                if (listenerMetaData != null && listenerMetaData.size() > 0)
                {
                    // Files have listeners so go through them in the same order
                    Iterator<EventListenerMetaData> listenerIter = listenerMetaData.iterator();
                    while (listenerIter.hasNext())
                    {
                        EventListenerMetaData elmd = listenerIter.next();
                        Class listenerClass = clr.classForName(elmd.getClassName());
                        String methodName = elmd.getMethodNameForCallbackClass(callbackClass.getName());
                        if (methodName != null)
                        {
                            // Separate listener class taking the PC object as input
                            Object listener = listenerClass.newInstance();
                            invokeCallbackMethod(listener, methodName, pc, clr);
                        }
                    }
                }
            }

            // Class listeners for this class
            List<String> entityMethodsToInvoke = null;
            while (acmd != null)
            {
                List<EventListenerMetaData> listenerMetaData = acmd.getListeners();
                if (listenerMetaData != null && listenerMetaData.size() > 0)
                {
                    // Class has listeners so go through them in the same order
                    Iterator<EventListenerMetaData> listenerIter = listenerMetaData.iterator();
                    while (listenerIter.hasNext())
                    {
                        EventListenerMetaData elmd = listenerIter.next();
                        Class listenerClass = clr.classForName(elmd.getClassName());
                        String methodName = elmd.getMethodNameForCallbackClass(callbackClass.getName());
                        if (methodName != null)
                        {
                            if (elmd.getClassName().equals(acmd.getFullClassName()))
                            {
View Full Code Here

Examples of org.jpox.ClassLoaderResolver

     * @return The field expression representing the required field of this object
     */
    public ScalarExpression accessField(String subfieldName, boolean innerJoin)
    {
        DatastoreContainerObject table;
        ClassLoaderResolver clr = qs.getClassLoaderResolver();
        try
        {
            if (mapping instanceof EmbeddedMapping)
            {
                // Any embedded fields can go straight to the main table if embedded there
View Full Code Here

Examples of org.jpox.ClassLoaderResolver

     */
    public BooleanExpression instanceOf(ScalarExpression expr)
    {
        if (expr instanceof ClassExpression)
        {
            ClassLoaderResolver clr = qs.getClassLoaderResolver();
            Class instanceofClass = ((ClassExpression)expr).getCls();
            Class fieldClass = clr.classForName(mapping.getType());
            if (!fieldClass.isAssignableFrom(instanceofClass) && !instanceofClass.isAssignableFrom(fieldClass))
            {
                // Field type and instanceof type are totally incompatible, so just return false
                return new BooleanLiteral(qs, mapping, true).eq(new BooleanLiteral(qs, mapping, false));
            }
View Full Code Here

Examples of org.jpox.ClassLoaderResolver

        StateManager sm = om.findStateManager(value);

        try
        {
            ClassLoaderResolver clr = om.getClassLoaderResolver();

            // Check if the field is attributed in the datastore
            boolean hasDatastoreAttributedPrimaryKeyValues = hasDatastoreAttributedPrimaryKeyValues(
                om.getMetaDataManager(), om.getStoreManager(), clr);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.