ADF mobile: How to pack a third party jars into apk

Hi Expert,
I am using Jdeveloper + ADF mobile 11.1.2.4 to develop an android application. In this application, I need to call some functions in the third party jar files.  I need to add the third party jars into my apk so that those classes can be found during runtime.
I followed section 17.1.1.1 to add the libraries into my project. However, after I deployed my app to the emulator and tried to run it, it reported "encountered error: classes not found". And I also found that the third party jars don't exist in libs/ directory of the apk. Do you know how to solve the problem: How to reference a third party jar files in my app and make sure it works?
Thanks,
Yan

Create a /libs directory within  Android project directory and copy the JAR files to /libs.
To build.properties add
external.libs.dir=libs

Similar Messages

  • How to add new third party jars into JDev - quick question

    Hi All
    We have some additional jars needed to include for use with our current ADF application.
    These jars are not for ADF components.
    These jars are for API calls to other 3rd application.
    We're using standalone weblogic to run our ADF app.
    How do we include our 3rd party jars in JDev ?
    Do we need to include new paths in standalone WLS to pick up these new 3rd party jars in order for our app to work ?
    Thanks

    You can add libraries to WLS classpath, but this is not good approach if you need to replace them later(because you must restart WLS to pick new version)
    To include jars to ADF deployment, open Model or ViewController project properties and include path(s) in Project Source Paths->Java Source Paths.
    Then edit your deployment profile (right click on application -> Application Properties... ->Deployment -> Your Deployment Profile), go to Application Assembly and mark these libraries(also, for each library you can specify target folder, for example "lib")
    Dario

  • How to Call third party Jar into Application

    Hi Can any Expert help ?
    I want to put third party Jar into my application but i have some problem occur.
    1. how to call jar with parameter in application ?
    2. when i exit the third party jar task, it will exit my main task too. How to set my main tast exit stats standalone ?
    3. I have over 10 jar files in one application, how can i set a classpath for client to call JNLP, instread of load all jar to client before run.
    Thanks.
    Sanki Poon ([email protected])

    1) Sounds like you are trying to launch the third party from it's application main instead of using it as an API How does your code interact with it or is that not important?. You don't call a jar, you load a class. You could use a exec http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Runtime.html to run the java launcher and pass it all it's command line stuff(But this may not be possible security wise via WebStart).
    2) if it is launched in the same JVM and it calls a System.exit there is nothing you can do about your app closing too. It would need to be in another instance of the JVM
    3) Under the resources tag you can have as many jar tags as needed.
        <resources>
            <j2se version="1.5.0" java-vm-args="-esa -Xnoclassgc"/>
            <jar href="/jsf-wita/apps/MathMLWebEditor.jar"/>
        </resources>

  • How to include a third party component into a netbeans project

    I am working in netbeans 5.0 and i want to include a third party component into my project.I have the jar files of a text editor ie FCK text editor.Could anyone tell me how to include the component into my project

    - Put the jar file on a location you want (the location must be the same for all developers).
    - Select the "Libraries" node of your project.
    - Press the right mouse button to bring up the popup menu and choose "Add JAR / Folder..."
    - Locate and select the JAR file you need and press OK.
    - Now you have included it into your project.

  • How to package third party jars into an ejb application?

    Hello everyone, thanks for reading...
    Does anybody can give me any hints or directions on how to include inside my .ear or .jar all the dependencies of all my EJBs?
    I need to deploy inside my ejb.jar or application.ear all the dependencies. The thing it's that I have a services-ejb.jar and it depends on several jars: services-api.jar, services-util.jar, ws-client.jar, etc.
    I read somewhere that these jars should be inside the META-INF/lib directory inside the ejb-jar. Is this correct?
    I deploy to Oracle Application Server and I'm using EJB 3.0.
    Thanks in advice.

    IDE and Maven have nothing to do with it.
    You need to look at your Oracle AS docs and put the 3rd party JARs in the directory where it expects to find them. I don't know where that is. Most Java EE app servers are different. WebLogic uses an APP-INF directory at the top level of the EAR file. I don't believe it's a Java EE standard. There's more variability in EAR arrangements than there is for WAR files. Those are standard.
    %

  • How to use a third party jar, which is added to classpath at runtime.

    Hi
    I'm using the classpathhacker posted on the forums somewhere, and want to use the jexcel driver.
    What I want is to be able to use the excel functions only if the excel driver is availlable.
    The problem now is that to be able to use the excel functions the driver has to be in the classpath, and it has to be imported when compiling.
    That way the app will crash at startup if the driver isn't availlable...
    Is there a way around this?

    Wouldn't it be possible to catch the error thrown when the JVM can't find the used classes? That would prevent the program to exit, or not?
    e.g.:
    try {
      // things that aren't available...
    } catch (Exception ex) {
      // error occured
    }

  • Plz suggest me How to use Third party jar files in ODI

    Hi all,
    I need to know how to use the third party jar files or our own customised jar file in ODI.
    regards
    palash

    Hi all,
    I am unable to implement..................
    I have one question, if I add any type 4 coneection supported jar file in my ODI_CLASSPATH can I use them in writing procedure to connect Databases
    I am trying to connect Oracle database by putting Ojdbc14.jar in the class path of ODI_CLASSPATH so that in my procedure I can use it .............but failed I dont know how to solve this problem.
    another thing Open Tools are delivered as a Java package (.zip or .jar) containing several files:
    A compiled Java .class file
    Other resources, such as icon files is it so ..............Then I can use full java apllication by preparing required bunch of classes and by set them appropriately in open tool
    need ur suggestion....
    regards
    palash

  • Where should the third party JAR files be placed ?

    Hi,
    We have a requirement to perform encryption / decryption of supplier bids. In this case we require to use third party provider JAR files with OA framework code. Where should the JAR files generally be placed in such a scenario ?
    Thanks and Regards,
    Sandhya

    Checkout this post.
    How to inclue a third party .jar file in OA fwk classpath Class not found

  • How to Deploy the third party EJB 3.0 jar in web application

    I have a web application which calls services provided by EJB 3.0 beans packaged in third party jar. How do a configure the ViewController project to deploy the beans to the weblogic server when I run the application rather than deploy the EJB ear as a stand application to the server?
    The jar file has already referenced by the project. In the "EJB Module" of project properties I've set the EJB Version property to 3.0, but the Annotated EJB 3.0 Bean Classes list remains empty, presumably because I have no beans defined in the sources of the application. When running the project the EJB jar did not deploy automatically. Is there something wrong? How can I achive this goal?
    Best Wishes~
    ELeven.Xu
    IDE: JDeveloper 11g (11.1.1.2.0)
    OS: Linux

    I don't think this technique will work. I added a META-INF/ejb-jar.xml file to the application, and added a <session> section for one of the EJB 3.0 beans from my third party jar. I specified values for <ejb-name>, <ejb-class>, and <session-type> hoping the rest of the configuration would be determined from the annotations in the class. When the server starts, this warning message is displayed:
    Oct 30, 2009 12:06:41 PM com.evermind.server.ejb.logging.EJBDeploymentMessages warningSessionBizInterfaceNotDefined
    WARNING: \[current-workspace-app: ... \] - The session bean does not has at least one business interface defined for client access. The bean is not accessiable and usable at runtime.
    Ready message received from Oc4jNotifier.
    Embedded OC4J startup time: 11042 ms.
    \[sic\]
    EJB 3.0 beans are not required to define business interfaces, as they are supposed to be generated by the container.
    Good idea, but still cannot deploy beans from the third party EJB 3.0 jar referenced by my project to the embedded OC4J container. Still investigating.
    Thanks,
    Steve
    By the way, I have been able to use your technique to deploy EJB 2.1 beans from third party jars in other projects, just not EJB 3.0 beans that do not provide ejb-jar.xml deployment descriptors, nor business interfaces.
    Edited by: user10375549 on Oct 30, 2009 9:51 AM - Added relevant comment regarding technique described for solving problem. It works for EJB 2.1 beans but not EJB 3.0 beans.

  • How do i enable third party cookies on my macbook pro?

    how do i enable third party cookies on my macbook pro?

    You mean in a particular browser?
    Safari>Preferences>Privacy>third party cookies

  • How do I allow third party cookies for a website and how do I turn off pop-up blocker?

    How do I allow third party cookies for websites and how do I turn off pop-up blocker?

    Allow third party cookies at Safari > Preferences > Privacy > Block Cookies - "Never".
    Turn off the pop-up blocker at Safari > Preferences > Security > Block pop-up windows = unchecked

  • How to include third party .jar files into my jar file

    Hi,
    how do i include a open source third party jar file into an executable jar?
    i have a class called BlogBox.java and it uses org.apache.commons.net.ftp.FTPClient, i want to create an executable file, where do i put the .jar file containing FTPClient aka Apache Commons Net?
    currently i'm getting the following error from when executing my BlogBox.jar
    C:\MyJava\BlogBox>java -jar BlogBox.jar
    Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/net/ftp/FTPClient
    at blogbox.BlogBox.<init>(BlogBox.java:27)
    at blogbox.BlogBox.main(BlogBox.java:103)
    Any suggestions? i have searched google and this forum but could not find the solution to my problem, thanks
    [edited msg] do i need to add the classpath at execution or something of the apache commons net library?
    Message was edited by:
    gekkokid

    When you use an executable jar the normal class path
    is ignored, but you can put a classpath inside the
    jar. The usual trick is to place the library jar
    files in a directory inside the application directory
    and direct the manifest file to it. The manifest file
    live in the jar inside the META-INF directory and
    it's called manifest.mf
    The two heavilly used entries are Main-class: and
    Class-path: lines. Class-path just has a
    comma-separated list of library paths.
    The jar utility has a special option to load it up.Thanks :) I created a "/lib" directory, placed in the packages in there and redirected the Class-Path: lib/commons-net-1.4.1.jar
    and it works,
    thank you everyone :)

  • How  to map the Third Party materila for Job Wok process in our Plant

    Dear All,
    please guide me how  to map the  Third Party  Subcontracting in Our Plant Means Customer materials to be Processed  in our Plant and  then we have to sent to customer after processing.
    please  Brief me  with the Proces sflow
    Reagrds
    kishore Edagali

    1) create a 2 material as non valuated (one incoming material "A1"& after processed material"B1")
    2) create a BOM. for A1
    & assign the B1 and maintain respective conversion
    3) create a routing for A1 and assign the relevant work center
    4) create a manual PO to receive the material from customer and store it in storage location
    5) create a production order and release the order  in co01
    6)issue the material :B1 to the order 9 in MB1a, 261 movement)
    7) and confirm the order (so that cost incurred for order is captured)
    8) create a  sale order and maintain service price in PR00 and send the material A1 to customer.

  • How can I enable third party cookies?

    How can I enable third party cookies?

    Demo, I just did some reseach on this question and while one an set iPad to accept cookies, from what I read, it doesn't work for 3rd party cookies.  Maybe I'm not getting it though, which is certainly possible..

  • How SAP handles AFS Third Party Orders in ECC system?

    Hi All,
    There is a user exit EXIT_SAPLJ3AM_003 which exist in 4.6C version of SAP for AFS.
    This user exit is for Third Party order processes. This is called within the include LJ3AMFD1 of the main program SAPLJ3AM.
    But this User exit is missing in ECC version of SAP for AFS.
    Basically when the Dierct ship Sales Order is created, corresponding PR is created for it and using this User exit certain fields in this corresponding Purchase Requisition is filled from Sales Order but this user exit is missing in ECC system.
    Could anyone please let me know how SAP handles the Third party Orders in ECC AFS system?
    Thanks,
    Ameesha

    Hi Ameesha,
    Did u find out any solution for it? bcoz, am also hving the same issue!!
    thanq

Maybe you are looking for