>> I have API.class in JVM and java settings in cf administrator. >> Today I tried create java object. I used following line: >> >> <cfobject class="mobi.mtld.da.Api" name="API" type="java" >> action="create"> > >First, I'd just put this class in WEB-INF/classes instead of some other >directory. That directory is already in the classpath. Second, your class >attribute indicates that the package is mobi.mtld.da, which means you need >that corresponding directory structure >(WEB-INF/classes/mobi/mtld/da/Api.class). > >I seem to recall you had a jar file, though. If so, you can put it in >WEB-INF/lib. Assuming it contains the package structure listed above, that >should be all you need to do. > >In either case, after adding your Java file to the appropriate directory, >restart CF. > >Dave Watts, CTO, Fig Leaf Software >http://www.figleaf.com/ > >Fig Leaf Software provides the highest caliber vendor-authorized >instruction at our training centers in Washington DC, Atlanta, >Chicago, Baltimore, Northern Virginia, or on-site at your location. >Visit http://training.figleaf.com/ for more information!
Today jar file is in WEB-INF/lib directory. But I have one more question to you. I found java code for this llibrary, but I don't konw java. Can you translae following code to cfml for my? HashMap tree = Api.getTreeFromFile("sample/DeviceAtlas.json"); HashMap prps = Api.getProperties(tree, "Nokia6680..."); Object prop = Api.getProperty(tree, "Nokia6680...", "displayWidth"); sample/DeviceAtlas.json - directory, where is located device database, "Nokia6680..." - in this part of code I have to use HTTP_USER_AGENT cgi variable. I should use array of java.util.HashMap. But I'm not sure. Can you help me again? Thanks a lot ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;203748912;27390454;j Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:307850 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4