Pages

Wednesday, December 25, 2013

Sharing VO instance Across the Application Module.

 In Previous post I say that how to access the common application module(CommonAM) via java class. As i said earlier that there is a lot of ways to achieve that.

If you see my previous post at that end of the post i say that "I'll later explain little more simplifier than this post."

here is the way. 
All setup of the application is same as of previous post. just all we needed to do two important steps to achieve that. 

Step 1: Current Application(WorkApp). it doesnt have any entity,view objects.the snap which is showing EmployeesView is under the model imported from ADFSharedLib.
Just shuffle the EmployeeView to right hand side that is WorkAM. now you can able access the ViewObject instance.




Step 2: Just same method But now I'm writing in WorkAM implementation class. somehow altering some piece of line make more simpler.





if i follow above for 'n' Application module. then code duplication we will happens each every Application module implementation class. so re-usability will fail in my case. not for all of your cases.

Step 3: let us check the db data for the employee id '100'.


Step 4: Now i'm going the run BC tester.


Step 5: check the db data again for the employee id '100'.





finally get updated. this simple techniques get works. 


In next post I'll explain this how to do this same via bean through Bean through Datacontrol.


Tuesday, December 24, 2013

Access Application module from simple Java Class.

I got a requirement like accessing AM from a java class

Say as e.g.:           
           
Where I have a common Application Module(name it as CommonAM from CommonApp). 
It folds of common Entity Objects, ViewObjects. this CommonApp make it as ADFSharedLib).
This ADFSharedLib invoked it in each and every 'n' Projects. 
Then I try to access that commonAM and its entities and views in other Projects.

Note:
I dont want to use a Bean to access the commonAM via DataControl. 

So, I want to use one Java Class across all other Application Modules.

There are lot of ways to achieve that.
Here I'm going to share one way.I'm not sure this recommend practice. but we can also do by the way.

Step 1: Following Figure that how my CommonApp looks just employee eo , vo.



Step 2: I packed the CommonApp as ADFSharedLib.



Step 3: I'm trying to invoke the ADFSharedlib from File system.


Step 4: By creating root application while invoking the method at run time. I can able to access my view objects instances. 

say as e.g.: Creating a programmatic view criteria find the employee id and updating the salary...

After commit. there is no need to act as root. so i release the resource.




Step 5: finally i invoke this from current working application. that is WorkApp.
I'm trying to execute that from WorkAM.



Step 6: before executing let us check the db data. Now for the employee id '100' having the salary 2400.



 Step 7: Now i'm going to execute this method from BC Tester.




Step 8: After execution let us check in db. salary of the employee. 


It's updated. 
By this way i can able to communicate with my commonAM.

CommonApp Download here

WorkApp Download here

I'll later explain little more simplifier than this post. check this post.

Saturday, November 30, 2013

Show web Pages imported from ADF libraries

Context i'm going to speaking is stated as in subject you can see that option in jazn-data.xml.

when it will useful you may ask.

Consider the Scenario your main application is fully bounded with help of ADFSecurity. your child application not having security,

if you are try to consume Taskflow from your child application to the main application. ADFSecurity wont allow unauthorized Taskflow invocation.
 

we should make entry in jazn.xml to make it authorized. However you can't able to see your Child Application Taskflow even after imported.


At that time check the option you can able to see that child application taskflow.

To confirm the above statement. here i gave the snapshots. 


Step 1: Secured Application(ADFSecuredApp).



Step 2: non - Secured Application(Genereal App).




Step 3: Make non-secured(GenerealApp) it as ADFLibrary. why mean i need the "general" task flow in secured application(ADFSecured App)



Step 4: you can see secured index page in ADFSecured Application

 
 

Step 5: Now in this ADFc-Config of Secured(ADFSecured Application) trying to invoke the non-Secured(Genereal Application). now if you run this page that taskflow never invoke.why because means not giving access to that bounded taskflow.
 

Step 6: Registering the Taskflow as Secured you can choose the Taskflow from drop down. but it is not avialable. even though you imported the non-secured(Genereal application). 


Step 7: Now By checking the box you can able to see the imported Taskflow.



Step 8: Now Make it as authorized.




Step 9: After that Running the ADFSecured Application.



Step 10: you can see your index page.




Step 11: finally i can able to invoke the Genereal Application Taskflow in ADFSecured Application.




Download here

Integrating the Taskflow in One Application.

Nowdays, Each and Every Application has own Taskflow flying on their own. Integrating the Taskflows is Main work.

Consider like this say as eg. 
First Application  -  folds of some Task Flow
Second Application -  folds of some Task Flow
Main Application   -  Consume/Integrate the Taskflow in Existing Application.


Major thing no need to duplicate all those things.In the Sense we can Re-use it.

Step 1: Try to deploy your ViewController of First Application.



Step 2: deploy it as ADFLibraryJar


 Step 3: Note it down the location after the jar deployed successfully.



Step 4: Use File Connection to invoke that ADFLibraryJar


Step 4: Test your Connection.


Note : upto this step to do the same for the Second Application also.

Step 5: Try to Add it to your main application.


 Step 6: finally I consumed two taskflow in my main application as a region.



Step 7: Main Page of your main application render the two consumed Taskflow of existing application.




Just i'm giving a picture about this topic. how to do. Based on their requirment you flex it.

Download here 

Adding Value change listener for run time input components

I got a requirement like adding listener at run time.
I found two ways.

way 1:
1. In this approach "setValueChangeListener" we can do.
2. By with the help of MethodBinding to invoke the listener in the  same class it self
3. MethodBinding and el class has been deprecated in this approach.

way 2:
1. In this approach "addValueChangeListener" we can do.
2. You need a additional class to perform this.
3. ProcessValueChange you can grab the value.

Step 1: Two methods are implemented




Step 2: final rendering of page.



 Download here

Tuesday, November 12, 2013

My Contribution towards OTN Forum

How I was started into OTN Forum?


When I was new to Oracle ADF, Whenever I got stuck up. Just I do Google. Most often, the results would be OTN forum posts. So, BTW, I started. Once I got to read their issues for a moment. At the end of the post answer can be found.


Very Often my issues have not posted by any one ever!!! Just I do login into OTN forum there I start to post my question.
While I was a Newbie, Most of the folks guided me to achieve the output. I had to thank them all.


Recently, I have got this Title.
                                         



One of the Top Participants in ADF UI Patterns & Best Pratices


 


Subramanian Meyyappan

ADF Security - JpsAnonymousRole Problem In Jdeveloper R1 Release

When I'm new to using
 Jdeveloper 11.1.1.6.0 and 
 Jdeveloper 11.1.1.7.0 

while i'm configuring ADF-Security to my Fusion web application.

[02:18:37 AM] Deploying Application...
<CodebasePolicyHandler> <migrateDeploymentPolicies> Migration of codebase policy failed. Reason: {0}.

oracle.security.jps.JpsException: java.lang.IllegalArgumentException: oracle.security.jps.internal.core.principals.JpsAnonymousRoleImpl

I got above error in those two Jdeveloper specific version only.   
I worked with Jdeveloper 11.1.1.4.0,11.1.1.5.0,11.1.2.4.0 Nothing like error reproduced. Apart from development. I wasted most of the time for investigation about this error. 

Don't ignore error which you had.Above error is not a show stopper.it will allow you to run the application. but you can get expected output.

To Avoid that,

<app-role>

<name>anonymous-role</name>

<class>oracle.security.jps.internal.core.principals.JpsAnonymousRoleImpl</class>

<display-name>anonymous-role</display-name>

</app-role>

Just remove this part of xml code from your jazn-data.xml.

Now your application will not re-produce any error log as of previously. it will works as you expect.

Saturday, October 26, 2013

"Import application error: Either this is not a valid name or an object with that name already exists. model.Model"

Intially First App as like of following Snap:



then Second App as like of following Snap:                          


Scenario:
                 while I'm importing jar in one another project. i got this warning and error message.





Resolution for the above problem is :

                 i realize that i'm having same model name and same package name and same application module name. after i rename all those things. 

Finally,
without any error jar imported successfully then it works fine.

Tuesday, October 15, 2013

af:tree on Oracle ADF

I am blogging out for whoever want to make af:tree without any code (i.e) zero line code.

Step 1: Have a ViewCriteria



Step 2: Invoke that View Criteria 
 
Finally,


Download here

Monday, October 14, 2013

How to use Oracle ADF Security on Fusion Web Application

This blog may helps out the people whoever new to this hot topic(ADF Security)
when I am new to this topic. I searched for simple document and along with an example on ADF Security. I didn't get chance have like that at that time.

This Oracle ADF Security docs which i followed. it may take little time to understand and experiment out as per the document. To avoid that i made it out a simple example.
As per my requirement(simple example on Oracle ADF Security giving little time to experiment). From the document i skipped some of the requirement steps.But i followed some core steps of ADF Security from this document.


For details:
see jazn-data.xml it will be in application resource under the application navigator.

In jazn-data.xml
go with users section      -  creating users
go with application role   -  creating roles.
go with resource grants    -  configuring access to pages.
For login credentials please check with jazn-data.xml.

Saturday, October 12, 2013

Oracle ADF Mobile Simple Tutorials with Sample

After the Completing the Guidance Start to learn the Simple Oracle Tutorials.
while deploying you can see the Deployment Log it takes much time for deployment to avoid that read this


Oracle ADF Mobile for Beginners Guidance

After a long time I got a chance to write a blog.

For Oracle ADF Mobile Beginner right origin to start learning. Please take a look on it.


Oracle ADF Mobile Intro

Oracle ADF Mobile Glance at once

Oracle ADF Mobile Top to Bottom[cover to cover for a developer]



Saturday, June 1, 2013

About Jdeveloper Pallette

Based On Otn Forum, I came up with this Post,
Unfortunately if you lost the palette from the jdeveloper tool means it would be like



Step 1:
Go Window It would be Present Top of the pane.



Step 2:
Choose Reset Windows to Factory Settings. Finally it would like this