How to access MDS in java
Hi,
I am looking for a way to access files in MDS in java.
I have some files (XSD's, XSLT etc) deployed to the SOA Suite MDS repostory and I would like to access them from some custom code, which is to be used in a custom XPath Extension Function.
Does anyone know how to get to the MDS repository from java?
I'm using SOA Suite 11.1.1.3.0
Groeten,
HJH
I found a way.
It was actually very easy.
In the SOA Runtime library there is a class oracle.fabric.common.metadata.MetadataManagerImpl.
Just instantiate it and go!
Groeten,
HJH
Similar Messages
-
How to access .asmx from java application
Hi All,
I want to access .asmx file using java application. I am using Eclipse IDE and created
some samples from this url: http://www.eclipse.org/webtools/jst/components/ws/M5/tutorials/BottomUpWebService.html
I got the Soap request and response format from wsdl file. But, i don't know access
the .asmx file. If u have any samples or give some suggestions that will be helpful for me to
proceedTry creating a page called launcher.html (for example). That does this:
<html>
<head>
<script language="javascript">
windowHandle=window.open("http://www.javasoft.com", "", "height=700,width=1000,status=no,scrollbars=yes,resizable=yes,toolbar=no,menubar=no,location=no,top=5,left=5");
</script>
</head>
</html>Now you launch IE (or whatever) with this page using the Runtime class. After x seconds (after the second window has been launched) try killing the process. Hopefully it will kill the original window you opened and not the window you popup (the one without toolbars etc)
It might kill both windows but I can't be bothered to test it. If it does you'll have to try and find a workaround. -
How to access database file on CDROM from Java Programe??
Hello friends,
I am making online exam application.
I want my question database to be reside on CDROM.
but i am not getting any idea how to make DSN or static path that resolute the path that i have mentioned for CDROM.
basically i want to know how to access CDROM from Java Programe????
Thanks in advance
Navik PathakOnce you mounted the CDROM (something maybe as /media/cdrom) as a file system (or assigned a drive letter to it like D: or F: or whatever), the files are accessible normally.
-
Hi All
can anyone pls let me know
how to access sap thru java stack like what is ipaddress and port etc.
Thanks in Advance
Arunyou can find full java administartion documentation at
http://help.sap.com/saphelp_nwce10/helpdata/en/c8/cdfacc37efa84d914699ad31eb69b8/frameset.htm
Also the link for accessing java page is
http://<full hostname>:<port>
full hostname- hostname of your SAP JAVA instance
port no- 50000+100*Instance number
Instance no- SAP system instance no
Rohit -
How to access PL/SQL Web Services using java
New to Webservices. Created PL/SQL Web Service using JDeveloper. Vendor is not sure how to access it using java. Can anyone please help to point in the right direction or provide some sample ?
So if I'm correct you have already exposed a PL/SQL procedure or function as web service?
In that case you can generate a proxy (client) for the generated web service using JDeveloper. It will generate Java code which invokes the web service.
See the wizard in JDeveloper, it should be in the same category as the create PL/SQL web service wizard.
Regards, Ronald -
Accessing connection from java and generated code
In JDeveloper 10.1.2.x I set up a connection and selected a stored procedure and generated java to call the stored proc. All good.
Now, in a web service application I want to call the method in that class that was generated.
So, the generated class has setConnectionContext(), getConnectionContext(), etc methods. I don't know how to use them. What is a ConnectionContext?
How do I provide the database connection information and call the method in the generated code that I need?
My Oracle AS server has a datasource configured that is the one I would like to use, but I don't know how to 'access' it via java in the context of this generated class.
I am deploying to Oracle AS 10.1.2,
thanksHi, well CSV is not currently an Excel file, it is a Comma Separated Values
file which can be read through Excel.
Now, if you wish to remove the header, I would purpose that you develop an
application that reads the CSV file, as it is mere text, and that it also reads
another file (lets call it confirguration.txt) in which you determine the pattern
you want to remove, then you just read your report and if a string line
matches the pattern you defined in the configuration.txt file, then you simply
erase it.
And if you keep interested in reading real Excel files (xls), I would
recommend you use POI-HSSF API from Apache.org
http://jakarta.apache.org/poi/hssf/index.html
Hope this helps, cya around. -
Hi all,
how to access OVD using Java?
Thanks,
Kumar.PHi,
You can just normal LDAP API codes to connect to OVD the same way you connect to other LDAP servers.
PFB sample code for connecting to OVD.
Properties props = new Properties();
try {
props.load(new FileInputStream("LdapCredentials.Properties"));
} catch (IOException e) {
// TODO
ldapurl = "ldap://hostname:390";
ldapUser = "cn=orcladmin,ou=Org12,dc=ovid,dc=com";
userPassword = "welcome1"; //"Killtheking123456";
userContext = "ou=Join1,dc=ovid,dc=com";
Now, you have to get Directory Context as shown below.
Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY,
"com.sun.jndi.ldap.LdapCtxFactory");
env.put(Context.PROVIDER_URL, ldapurl);
env.put(Context.SECURITY_AUTHENTICATION, "simple");
env.put(Context.SECURITY_PRINCIPAL, username);
env.put(Context.SECURITY_CREDENTIALS, password);
//Initialize the Directory context
DirContext dCtx = new InitialDirContext(env);
Then you can perform search operations or new user creation etc., as you wish.
Does this help?
-Mahendra. -
How to control browser from java program?
I want to retrieve the url currently loaded in my default browser. How to achieve this task using java program? I dont know how to access browser using java.
Peter__Lawrey wrote:
Actually Desktop.open only works for downloaded pages.
Instead you can use this to get the browser to download the page and display it.
Desktop.getDesktop().browse(URI.create("http://www.google.co.uk"));
First of all thanks for your reply Mr Peter__Lawrey.
I want to just retrieve the urls loaded in the default webbrowser, not the content of the url or the task of opening the default browser with the specific url. -
How to access .asmx Web Service using JAVA? Newbie
Hello Experts,
Currently, I have a project where in I have to access a ,NET web service. It is made of C#. I just want to ask how will I start the accessing process? I made this simple equation on how my project is.
Java Project + C#.Net Web Service = Integration
1. Do i need to create a Web Service too for the Java Project? If yes, What are the necessary tools needed for the creation of this Java Web Service?
2. The .NET Web Service is available online. (It is made by other people).
3. Based on the equation, what is the equivalent technology for the + sign?
4. Can you site a concrete example for accessing a web service?
5. I'm new here. Totally I have no idea where to start.
6. Thank you experts.
Edited by: Benedict.Aluan on 05 30, 08 1:38 PM
Edited by: Benedict.Aluan on 05 30, 08 1:39 PMHello
Thanks a lot for your help ...
I am developing simple J2EE based web service client using IBM WSAD 5.1. I have used the following code to call .asmx web service in Java
String url = "http://www.w3schools.com/webservices/tempconvert.asmx?wsdl";
String namespace = "http://tempuri.org/";
name = request.getParameter("txtName");
try
System.out.println("In Internet Service");
ServiceFactory factory = ServiceFactory.newInstance();
Service serv = factory.createService(new URL(url),new QName(namespace,"TempConvert"));
System.out.println("Got Service......");
Call obj = (Call)serv.createCall();
System.out.println("Got Call......");
obj.setProperty(Call.ENCODINGSTYLE_URI_PROPERTY,"");
obj.setProperty(Call.OPERATION_STYLE_PROPERTY,"wrapped");
obj.setTargetEndpointAddress(url);
obj.setPortTypeName(new QName(namespace,"TempConvertSoap"));
obj.setOperationName(new QName(namespace,"FahrenheitToCelsius"));
obj.addParameter("param1",XMLType.XSD_STRING,String.class,ParameterMode.IN);
obj.setReturnType(XMLType.XSD_STRING);
System.out.println("Parameters Set.....");
Object[] params = new Object[]{name};
k = (String)obj.invoke(params);
System.out.println("Result: "+k);
catch(Exception e)
System.out.println("Exception is : "+e);
}But this code is throwing exception that
Invalid Address "http://www.w3schools.com/webservices/tempconvert.asmx?wsdl"I have also tried this URL with Java Proxy. But it showing the same error.
Plz can u tell me how to access .asmx web service ?
Waiting 4 reply. -
How to access a JAVA Script variable in JSP Code
How to access a JAVA Script variable in JSP Code. I have been unable todo this.
Plz Suggest a way.
Thanks
Soumyatry to do this code
String s=request.getParameter("javascriptvariablename"); -
How to access methods in existing dll file from java
I have a dll file and that file contains two methods.
Now I would like to access those two methods in java program.
How to access these methods.
Give me the sample code for this problem.http://forum.java.sun.com/thread.jspa?threadID=757125&tstart=0
-
How to access variables declared in java class file from jsp
i have a java package which reads values from property file. i have imported the package.classname in jsp file and also i have created an object for the class file like
classname object=new classname();
now iam able to access only the methods defined in the class but not the variables. i have defined connection properties in class file.
in jsp i need to use
statement=con.createstatement(); but it shows variable not declared.
con is declared in java class file.
how to access the variables?
thankshere is the code
* testbean.java
* Created on October 31, 2006, 12:14 PM
package property;
import java.beans.*;
import java.io.Serializable;
public class testbean extends Object implements Serializable {
public String sampleProperty="test2";
public String getSampleProperty() {
return sampleProperty;
}jsp file
<%@ page contentType="text/html;charset=windows-1252"%>
<%@ page import="java.sql.*,java.util.*"%>
<html>
<head>
<title>Schedule Details</title>
</head>
<jsp:useBean id="ConProp" class="property.testbean"/>
<body>
Messge is : <jsp:getProperty name="msg" property="sampleProperty"/>
<%
out.println(ConProp.sampleProperty);
%>
</body>
</html>out.println(ConProp.sampleProperty) prints null value.
is this the right procedure to access bean variables
thanks -
How to access java method in JSP
Hi all,
I need to access java class (abstract portal component) method doContent() in a JSP which is under PORTAL-INF/jsp folder.
I did
<%@ page import = "com.mycompany.Aclass" %>
<%com.mycompany.Aclass a = new com.mycompany.Aclass (); %>
Aclass is coming as autofill/prepopulated with cntrl+space
Till this time, it is working. no errors. But when I do
a.
a. (a dot) no methods are populating (autofill..cntrl+space) or If I forcebly add method a.doContent(req,res)... at runtime its giving error.
It's not only with doContent method... Its with any simple methods in that class or any other class.
(Other than doContent method in the APC java class are prepopulating/autofilling but giving error in runtime)
Can anyone help me... how to access java method in JSP.
I already gone through many SDN forum post... and implemented too---but no use I refered below forum thread
Retrieve values from Java class to JSP
URGENT! How to call a java class from JSP.
Calling a java method from jsp file -
this thread is same as my issue
Thanks,
PradeeP1st. The classes must be in packages. 2nd, the package that they are in must be under the WEB-INF/classes directory. 3rd Look on google and/or this site for web application deployment
-
How to access XI_AF_MSG table in Composite Application Framework Java Code
Hi Experts,
I've no knowledge about PI. In one of my projects, I need access the XI_AF_MSG table of PI through java code in a composite application.
How do I access this table? I've searched this forum for this query but the replies say that any SQL editor can be used to access XI_AF_MSG table. But my question is; How do I get the login details of the database? In the first place, how do I access the underlying database layer of PI? Is there any JAR file which can be used to make the connection?
It would be of great help if any expert on this can give me a detailed reply.
Thanks a lot in advance.
Best Regards,
NitinHi Nitin,
The AFW runs on the J2EE Engine, so this table is in the Java Schema of the database and thus not visible in the ABAP stack. I guess you can use any tool your database provider offers for looking at table contents (e.g. SQLPlus).
Regarding how to access the table please contact you basis administrator they will have access to the tables as they have j2ee_admin login ids and pwds.
Regards
joel -
How to access application vars into JavaBeans or Java File?
I have the application directory strcuture like this. I am using Apache Tomcat/6.0.14 and Eclipse IDE.
-/MyFirstServlet
-/MyFirstServlet/WebContent
-/MyFirstServlet/WebContent/WEB-INF/web.xml
-/MyFirstServlet/WebContent/web.jsp
-/MyFirstServlet/Src
- com.model.DAO/userDAO.java (java class within package)
I have put following code into "web.xml".
==================================
<?xml version="1.0" encoding="UTF-8"?>
<web-app id="WebApp_ID" version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
<display-name>
MyFirstServlet
</display-name>
<context-param>
<param-name>DBDriver</param-name>
<param-value>com.microsoft.sqlserver.jdbc.SQLServerDriver</param-value>
</context-param>
<context-param>
<param-name>connectionUrl</param-name>
<param-value>jdbc:sqlserver://localhost:1433;databaseName=MyFirstServletDB;user=hitesh;password=hit
esh;</param-value>
</context-param>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.jsp</welcome-file>
</welcome-file-list>
</web-app>
I am easily able to access from "web.jsp"
===================================
String DBDriver = application.getInitParameter("DBDriver");
out.println("<br>DBDriver:==="+DBDriver);
String connectionUrl = application.getInitParameter("connectionUrl");
out.println("<br>connectionUrl:==="+connectionUrl);
BUT when I try to access withing userDAO.java it gives "application is not resolved"
========================================================================
String DBDriver = (String)application.getInitParameter("DBDriver");
NOTE: I understand I need to import some inbuilt java package which will allow to use applcation vars
within java class.
What is that package? and how to do that?
Is there any other easy method to use global/application vars which can be used in all
JSP/JavaBeans/Java files?
Thanks in advance.It might be easier to put that code somewhere else. JSP's are for presentation, not for accessing databases, business logic, etc.
Maybe you are looking for
-
What do I need to download to pen Canon CR2 files in CS5?
-
ADAPTER.SOAP_EXCEPTION:Maximum request length exceeded.
Hi frnds, Plz look for the error i am getting when sending large record... - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1"> <SAP:Category>XIAdapter</SAP:Categor
-
How can I recover the URL line; how can I recover the ability to backtrack?
I'm not super tech savvy. I didn't know what had happened when the system shifted from having a url line displayed with "back" and "forward" arrows. Now, I don't know how to: 1)Find a url address so I can copy a url in order to send someone a link to
-
HT3275 What does sparsebundle already in use mean?
I have two Macbook pros in use on this time capsule. I only get this message from one of the laptops. Any suggestions?
-
How do I download Adobe Reader 11. I have a 4 year old MacBook and it will only let me download the Adobe Reader 10.