Rajesh Navduri

Ranch Hand
+ Follow
since Jun 28, 2001
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Rajesh Navduri

Hi,

I am trying to run a simple page flow using tomcat 5.5.25 but I am not able to run a controller. I am able to run my JSP but not contorller.jpf.
Please somebody help me.

Jsp:

<%@ page language="java" contentType="text/html;charset=UTF-8"%>
<%@ taglib uri="http://beehive.apache.org/netui/tags-databinding-1.0" prefix="netui-data"%>
<%@ taglib uri="http://beehive.apache.org/netui/tags-html-1.0" prefix="netui"%>
<%@ taglib uri="http://beehive.apache.org/netui/tags-template-1.0" prefix="netui-template"%>
<netui:html>
<head>
<title>Web Application Page</title>
<netui:base/>
</head>
<netui:body>
<p>
Testing
</p>
</netui:body>
</netui:html>

Controller.java:

import javax.servlet.http.HttpSession;

import org.apache.beehive.netui.pageflow.PageFlowController;
import org.apache.beehive.netui.pageflow.annotations.Jpf;


@Jpf.Controller(
simpleActions={
@Jpf.SimpleAction(name="begin", path="Rajesh.jsp")
}

)
public class Controller
extends PageFlowController
{
/**
* Method that is invoked when this controller instance is created.
*/
protected void onCreate()
{
}

/**
* Method that is invoked when this controller instance is destroyed.
*/
protected void onDestroy(HttpSession session)
{
}
}


-------------
Web.xml:

<?xml version="1.0" encoding="UTF-8" ?>

<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

$Header:$
-->
<web-app 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"
version="2.4">

<display-name>ana</display-name>

<!-- Filter to perform Page Flow operations when JSPs are hit directly. -->
<filter>
<filter-name>PageFlowJspFilter</filter-name>
<filter-class>org.apache.beehive.netui.pageflow.PageFlowJspFilter</filter-class>
</filter>

<!-- Filter to perform Page Flow operations when JavaServer Faces pages are hit directly. -->
<filter>
<filter-name>PageFlowFacesFilter</filter-name>
<filter-class>org.apache.beehive.netui.pageflow.PageFlowFacesFilter</filter-class>
</filter>

<!--
It is possible - but certainly not required - to keep source files such as page flows and
JavaServer Faces backing beans mixed in with web content. In this case, and when the web
content directory itself is being deployed without being copied to some other build
location, it is important to prevent the source code from being URL-addressable. This
filter returns a specified error code when source files are requested.
-->
<filter>
<filter-name>PageFlowForbiddenFilter</filter-name>
<filter-class>org.apache.beehive.netui.pageflow.PageFlowForbiddenFilter</filter-class>
<init-param>
<param-name>response-code</param-name>
<param-value>404</param-value>
</init-param>
</filter>

<filter-mapping>
<filter-name>PageFlowJspFilter</filter-name>
<url-pattern>*.jsp</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>

<filter-mapping>
<filter-name>PageFlowJspFilter</filter-name>
<url-pattern>*.jspx</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>

<filter-mapping>
<filter-name>PageFlowFacesFilter</filter-name>
<url-pattern>*.faces</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>

<filter-mapping>
<filter-name>PageFlowFacesFilter</filter-name>
<url-pattern>*.jsf</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>

<!-- Prevent URL access to Java source code. -->
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.java</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>

<!-- Prevent URL access to JavaServer Faces backing beans. -->
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.jsfb</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>

<!-- Prevent URL access to shared flow source files. -->
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.jpfs</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>

<!-- Configuration/init listener for NetUI framework -->
<listener>
<listener-class>org.apache.beehive.netui.pageflow.PageFlowContextListener</listener-class>
</listener>

<!-- Listener to create NetUI framework HttpSession mutex objects -->
<listener>
<listener-class>org.apache.beehive.netui.pageflow.HttpSessionMutexListener</listener-class>
</listener>

<!-- NetUI Servlet Configuration -->
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>org.apache.beehive.netui.pageflow.PageFlowActionServlet</servlet-class>
<init-param>
<param-name>config</param-name>
<param-value>/_pageflow/struts-config.xml</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>

<!-- The XmlHttpRequest handler Servlet -->
<servlet>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<servlet-class>org.apache.beehive.netui.pageflow.xmlhttprequest.XmlHttpRequestServlet</servlet-class>
</servlet>

<!-- Struts Action Servlet Mappings -->
<!-- Note that because Struts takes the *last* mapping here as the extension to add to
actions posted from forms, we must have *.do come after *.jpf (etc.). -->
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.jpf</url-pattern>
</servlet-mapping>

<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>

<!-- XmlHttpRequest Servlet -->
<servlet-mapping>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<url-pattern>*.xhr</url-pattern>
</servlet-mapping>

<servlet-mapping>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<url-pattern>*.render</url-pattern>
</servlet-mapping>

<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
</web-app>

------------------

I think I am missing something in my web.xml..
16 years ago
Hi,

I have to read a system property from the tomcat 4.1. I have made the following changes..

1. In my catalina.bat after this line
set CATALINA_OPTS=%CATALINA_OPTS% -Dsun.io.useCanonCaches=false
I have addded -DEnv=dev
2. In my java file
String env = System.getProperty("Env");

But I am getting this env field as null.

Can someone suggest me how to get the system properties from tomcat.

Cheers
Rajesh
19 years ago
Hi,

I have to print some PDF files located in the Server from the client PC to a predefined printer which is configured in another machine say \\myserver. Now I need to get the printer name on that machine and print PDF files on that printer.

Pl suggest


Regds
Rajesh
19 years ago
Hi,

I am new to IReports. Can some pl tell me how to setup the IReports. I have downloaded IReports 0.4.0 and my DB is DB2 and JDK version is 1.4.1

Regds
Rajesh
Hi,

I am new to IReports. Can some pl tell me how to set up the IReports so that I can start generating Jasper reports. I am using Db2 as my DB.

Regds
Rajesh
19 years ago
Hi,

Our application is running on Tomcat 4.1 and DB2 7.2 and it is working fine. Recently we moved to DB2 8.0 and I am getting the following error.

java.lang.UnsatisfiedLinkError: SQLAllocEnv
at COM.ibm.db2.jdbc.app.DB2Driver.SQLAllocEnv(Native Method)
at COM.ibm.db2.jdbc.app.DB2Driver.<init>(DB2Driver.java:244)
at COM.ibm.db2.jdbc.app.DB2Driver.<clinit>(DB2Driver.java:129)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:140)
at com.ocg.apa.util.ConnectorHelper.getDBConnection(Unknown Source)
at com.ocg.apa.util.ConnectorHelper.getConnection(Unknown Source)
at com.ocg.apa.db.provider.DBDataProvider.transmit(Unknown Source)
at com.ocg.apa.db.DataTransceiver.transmit(Unknown Source)
at com.ocg.apa.db.DataService.transmit(Unknown Source)

This is what is there in my classpath
C:\>echo %classpath%
.;C:\PROGRA~1\IBM\SQLLIB\java\db2java.zip;C:\PROGRA~1\IBM\SQLLIB\java\db2jcc.jar;C:\PROGRA~1\IBM\SQLLIB\java\sqlj.zip;C:\PROGRA~1\IBM\SQLLIB\bin;C:\PROGRA~1\IBM\SQLLIB\java\common.jar

Can anyone help in this?

Regds
Rajesh
19 years ago
Thanks adam, this is what I need.
21 years ago
Hi,
I am new to Struts. I have a seen a file with .do extension. Can anybody tell me what this file does and where will we use this in struts frame work??
Regds
Rajesh
21 years ago
Hi,

I have a class A which has 3 methods (m1, m2 & m3) and I have extened class B which has m2 method.
In my test class I am calling the method m1 as
classB.m1 which in turn calls m2.
Now whats happening is, instead of my overloaded method (m2), my test class is calling the super class's (class A) method m2.
Because of this the changes I have made in method m2 of class B are not getting reflected.
Is there any way to access my classB's method than the ClassA's method??
regds
Rajesh
21 years ago
Hi,
I am new to the SOAP. I have created a class with main method, through which I have sent a SOAP request.
On the otherside I want to read this request using a servlet and send response back to the original class.
I cud able to send the response to the servlet. But I am unable to read this response in my servlet.
pl suggest.

Rajesh
21 years ago
Thanks Guennadii. It worked now.
Hi,
I am using jbuilder 7.0. I want to specify the context as 'cag/psnrweb'. But when I give like that jbuilder throwing an error.
"No appropriate node to show Web view for /cag/psnrweb/test.jsp, but the web server has been started"
Can anyone tell me how to set a desired contextRoot in Jbuilder.

Regds
Rajesh
Hi Ajith,
In our project we need to create tree structure display the product details.
-----Product---
----Date---
----Place---
----Details---
Like this we have show the details for each product.
Now the question is which will give a better view either DHTML or XML ??
In case of XML, how we can build this Tree like structure ?? Is there any built-in or any sample code to meet the requirement.
While I was looking for this info, I came across about IBMs xmltreediff. Is this useful for my present requirement ??
We are using Oracle9iAS as our application server and jsp. Pl suggest.
Cheers
Rajesh
[ March 25, 2002: Message edited by: Rajesh Navduri ]
Hi,
Can anyone tell me how to get a tree structure in xml ?? I found one topic regarding xmltreediff in IBM alpha works. Will it be helpful in getting the tree structure ??
How about getting this tree structure using DHTML
Pl advise.
Cheers
Rajesh
Hi,
You can create a servlet and make it as load at start up.
This will start and stop when you start and stop the server respectively.

Regds
Rajesh
22 years ago