Play sound(wav audio) in Java

Play sound(wav audio) in Java

Just for fun or for some application need, java provides functionality to play audio file. This is inbuilt in java and do not need any additional library. Following is simple code to play an wav file in java.


package play_audio;

import java.io.File;
import javax.sound.sampled.AudioFormat;
import javax.sound.sampled.AudioInputStream;
import javax.sound.sampled.AudioSystem;
import javax.sound.sampled.DataLine;
import javax.sound.sampled.SourceDataLine;

/**
*
* @author Yusata Infotech
*/
public class play_audio {
public static void main(String[] args) {

try {
System.out.println("Start");
File f = new File("d://wavs//beep-1.wav");
AudioInputStream audio = AudioSystem.getAudioInputStream(f);
AudioFormat format;
format = audio.getFormat();
SourceDataLine auline;
DataLine.Info info = new DataLine.Info(SourceDataLine.class, format);
auline = (SourceDataLine) AudioSystem.getLine(info);
auline.open(format);
auline.start();
int nBytesRead = 0;
byte[] abData = new byte[524288];
while (nBytesRead != -1) {
nBytesRead = audio.read(abData, 0, abData.length);
if (nBytesRead >= 0) {
auline.write(abData, 0, nBytesRead);
}
}
} catch (Exception E) {
System.out.println(E.getMessage());

}
}
}

Generate Code128, QRCode, PDF417 Barcode in Java

Generate Code128, QRCode, PDF417 Barcode in Java:

A barcode is an optical machine-readable representation of data. The data which it represents, can be get back by machine reading it. Originally barcodes represented data by varying the widths and spacing of parallel lines, and may be referred to as linear or 1D barcode. Today there are number of barcodes used for many a purposes.

In Java, we may need to generate a barcode for some particular string. The generated barcode can be used for printing labels etc. Following is an example of generating barcode from java using ZXing api of google. It is open source api which can be used for generating barcodes for several types. Following is simple java program to generate various barcode(code128, QRCode and pdf417(Mostly used on drivers license in USA)) using ZXing.


package barcode;

import com.google.zxing.BarcodeFormat;
import com.google.zxing.Writer;
import com.google.zxing.client.j2se.MatrixToImageWriter;
import com.google.zxing.common.BitMatrix;
import com.google.zxing.oned.Code128Writer;
import com.google.zxing.pdf417.encoder.PDF417Writer;
import com.google.zxing.qrcode.QRCodeWriter;
import java.io.File;
import java.io.FileOutputStream;

/**
*
* @author Yusata Infotech
*/
public class Barcode {
public static void main(String[] args) {
BitMatrix bitMatrix;
Writer writer = new QRCodeWriter();
try {
// Write Barcode
bitMatrix = new Code128Writer().encode("123456789", BarcodeFormat.CODE_128, 150, 80, null);
MatrixToImageWriter.writeToStream(bitMatrix, "png", new FileOutputStream(new File("D://code128_123456789.png")));
System.out.println("Code128 Barcode Generated.");
// Write QR Code
bitMatrix = writer.encode("123456789", BarcodeFormat.QR_CODE, 200, 200);
MatrixToImageWriter.writeToStream(bitMatrix, "png", new FileOutputStream(new File("D://qrcode_123456789.png")));
System.out.println("QR Code Generated.");
// Write PDF417
writer = new PDF417Writer();
bitMatrix = writer.encode("123456789", BarcodeFormat.PDF_417, 80, 150);
MatrixToImageWriter.writeToStream(bitMatrix, "png", new FileOutputStream(new File("D://pdf417_123456789.png")));
System.out.println("PDF417 Code Generated.");
} catch (Exception e) {
System.out.println("Exception Found." + e.getMessage());
}

}
}

QRCode



Code128



PDF417

Download ZXing Library here

What is Multi Level Marketing (MLM)?



Rancor Infotech Pvt. Ltd. manages this blog, is the fast progressing Software Development Company. We develop various Softwares which includes MLM Software, Inventory Software, ERP Software and many more. You can contact us at +91-9999671076 and Email ID is info@rancorinfotech.com.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

MLM Software
Multi-Level-Marketing (MLM)
MLM or multi level marketing is just another form of network marketing. With a combination of direct selling and franchising, process of multi level marketing comes into practice. During the process of MLM, new members are created in a chain so that they can sell or distribute the products. The chain continues as the members you have recruited recruit other members and the hence the chain goes on. Longer the chain you are having in MLM, better the profits you would be attaining. Members who are linked with the chain of MLM work on the compensation that is earned by selling the products. 

MLM or multi level marketing is also termed as pyramid marketing. Today, various multinational companies are offering MLM opportunity to people so that they can work and earn as much as they can. MLM business is preferred for use by many professionals who want to earn something extra. MLM has come to people as a business opportunity that will leverage their earning capacity. MLM works on a simple concept of recruiting people and promoting the goods. Once you have recruited people, they come under you as your downlink assistance. Even when doing the recruitments, you have to specify your team members that, they have to promote the products, which are being offered because it is the only way to earn profits. 

Before joining any MLM business, it is important that you do intense research work on the programs, which are offered by any company so that you are not duped of your hard earned money that you will be investing for being a part of the MLM business network.

Credit Card Validation Process

Work Nature
Online Data Entry on Portal
Input Type
PDF / TIFF / JPG / GIF
TAT
25 days
QC Report
10 days after TAT
Payment
Within 5 days of QC Report
Payout
Rs.7 per form
Workload
6500 forms per system / TAT
Registration Fee
Rs.12000.00 per system
Website setup & Training
Rs.500 per system
Agreement Type & Period
SLA for 11 months
Accuracy Required
90.1% minimum required for payment eligibility
Payment Terms
98.1% to 100% = Full payment
95.1% to 98% = 60% payment
90.1% to 95% = 30% payment
Below 90.1% = No Rework / No Payment


Technical Requirements
Windows OS(XP or 7) / Adobe reader / Image Viewer
Internet connection / Google Chrome Browser

Payment Mode
Cheque / Wire Transfer / DD
Royalty
NIL
Required Documents
Company Profile and LOI with Registration Payment
Signup Procedure
Direct or Online Signup 7 days to start live after signup
TOTAL INCOME-RS.45,500.00/ MONTH/SEAT

Regarding Automation You have 2 option:
1. Convert data to word thru abyfinereader check and put 5 semi colon in each data then upload using software. Software cost is Min Rs50,000 For 5   ID(This Cost Is One Time For Whole Project Period)
2. You will be provided data in excel or note pad with Semicolon you have to check data and upload through software. The cost of this service will be Rs 2  per record

E-LIBRARY PROCESS (PDF TO WORD)

(This is a West Bengal Govt Process)


NATURE OF WORK: Offline PDF to Word, copy & paste & formatting

PAYOUT: INR 20 - 50 per page

WORKLOAD: 400-600 images / month

MINIMUM SEATS: 1 system to unlimited systems

DURATION OF PROCESS: 1 year (Renewable)

MONTHLY BILLING: 20,000 INR - 30,000 INR for 1seat

BILLING CYCLE:  10 days

TAT: 20 days
PROCESS SOFTWARE: Training will be provided free of cost
SECURITY: No termination, 100% payment 
                  PDC of our Corporate A/c & Legal Agreement will be given
COMPANY CHARGES: Minimum INR 300/- per seat

CONSULTANCY: INR 50,000 only ( one time & non refundable )  
THIS IS A WEST BENGAL GOVERNMENT PROCESS & 
IT IS A DIRECT CLIENT SIGNUP WITH THE CLIENT


Royalty : NIL
Required Documents : Company Profile and LOI

Signup Procedure:
Direct or Online Signup. Immediately start live after signup.

MAIL YOUR REQUEST  TO shivshakti@sansinfotech.in

Work Details:

1. This is no accuracy process.
2. You need to copy-paste from pdf to Word.
3. And needed to do some formatting.
4. Like page margin, page size, headings size & color, etc.
5. And then needed to submit the Word files.


For further clarification or doubts call me or mail me.
shivshakti@sansinfotech.in
+91-8455916150 



Telecom Form Filling

Payout: Rs. 8/- per form will be given

Work load: Minimum 3000 forms per month for 1 system (minimum 3000 forms for each
system/seat)


Payment: 25% of the job work done will be given as an advance payment after 8 days(for the 1st TAT only) of going live to those associates those who meet the prerequisites from completion criteria. 


The rest of the payment for the 1st TAT will be sent to the associates after 15 days based upon your QC Report after QC Analysis for 6 days. 

From the 2nd to the 11th TAT payment will sent after 15 days based upon your QC Report after QC Analysis for 6 days.

Security Deposit:

INR 5,000 per seat as Data Security Deposit (Refundable after successful
completion of 11 months)

 


Payment Security:
Bank Guarantee to be provided for clients taking more than 40 seats.
QC Software: The software generates QC report the same day..


THIS IS A DIRECT CLIENT SIGNUP PROCESS WITH THE ONLY INDIAN AUTHORIZED
REPRESENTATIVE OF THE TELECOM COMPANY


Direct client signup
Bank Guarantee:- Minimum 40 seats (The center has to bear all the banking charges)
Data Security Deposit:- Rs-50,000/- for 10 seats minimum
Billing:- 24,000/seat/month
Refund:- After completion of the contract
Client is having 68 centers all over India
Royalty:- 5%
Consultancy:- Rs.- 50,000/- only (At the time of sign up)



For further clarification or doubts call me or mail me.
shivshakti@sansinfotech.in
+91-8455916150

Required Documents : 
- Company Profile and LOI (Letter of intent.)
- Company Legal Documents
- Infra pictures 


Signup Procedure:Direct or Online Signup same day to start live after signup.

MAIL YOUR REQUEST/COMPANY PROFILE TO shivshakti@sansinfotech.in



Closing Ugent basis!

MIMS FORM FILLING PROCESS

Work Nature : Online Data Entry on Portal
Input Type : PDF / TIFF / JPG / GIF
TAT : 20 days
QC Report : 10 days after TAT
Payment : Within 5 days of QC Report
Payout : Rs.5 per form
Workload : 5000 forms per system / TAT
Registration Fee : Rs.7000.00 per system
Agreement Type : SLA
Period : 11 months

Payment Terms :

98.1% to 100% = Full payment
95.1% to 98% = 60% payment
90.1% to 95% = 30% payment
Below 90.1% = No Payment

Max Monthly Billing =
Rs.25,000/- per seat


Technical Requirements :
Windows OS (XP or 7) / Adobe reader / Image Viewer
Internet connection / Google Chrome Browser

Accuracy Calculation Method :

Spelling Error = 10 px
Field Mismatch / Field Missing / ID Error = 15 px
Case Error / Date Error / Space Error = 8 px
Record Missing = 50 px
100 px = 1% accuracy
Quality% = (No. of Errors X px = Total px) / 100 = (Error%) 100% - Error%

Payment Mode :
Cheque / Wire Transfer / DD

Royalty : 5%
Required Documents : Company Profile and LOI with Registration Payment

Signup Procedure:
Direct or Online Signup 7 days to start live after signup.

MAIL YOUR REQUEST  TO shivshakti@sansinfotech.in


Auto MIMS Form Filling Software (OPTIONAL)

Used for uploading data will cost Rs30,000 For 5 IDs

Conversion Software (OPTIONAL)
 

Needed when using auto MIMS Form Filling Software. It's FREE of cost.

Conversion Service
Converting the data in excel sheet With Semicolon will cost Rs 2 per data.

 
Project Cost
5 IDs - Project Registration charge (Rs.35,000) + Consultancy charges extra
 

Demo Work

For Demo work use below link:

www.medinfo-source.com
User Name : demo555  password : demo555

For further clarification or doubts call me or mail me.
shivshakti@sansinfotech.in
+91-8455916150 

HTML TAGGING PROCESS


(For experienced centers only)
(Freshers will be trained by us)

PAYOUT: Rs. 70 per page
PAGES: 500 pages/month/agent
MINIMUM BOOKING: 5 systems

SECURITY DEPOSIT: Rs. 6,000/- per seat (Refundable)
(Security deposit + 12.36% service tax)
TAT: 15 days
QC REPORT: After 10 working days
PAYMENT: Within 3 working days of the qc report
BELOW 40% ACCURACY: Seat gets terminated (Rework Available)
PROJECT DURATION: 11 months

Payment Mode : Cheque / Wire Transfer / DD
Royalty : NIL
Required Documents : Company Profile and LOI with Registration Payment
Signup Procedure:
Direct or Online Signup 3 days to start live after signup.

MAIL YOUR REQUEST  TO shivshakti@sansinfotech.in


Proof Reading Software (OPTIONAL)
 Used for proof reading pages. 
To buy, It costs Rs.1,00,000 For 5 IDs
To rent, It costs Rs.5,000 per seat

Conversion Software (OPTIONAL)
 
 
It's FREE of cost. But you need to develop it's pattern. 
Pattern developing is very tough and time taking. 
So you can use our conversion service.

Conversion Service
Converting the data in notepad/MS Word will cost Rs 10 per page.
 
Project Cost
5 IDs - Project Registration charge (Rs.30,000) + Consultancy charges extra
 
Demo Work

For More Details & Demo work use below link:
Click here to download process details


(IF YOU WANT DIRECT CLIENT SIGNUP, 
THEN  OUR CONSULTANCY WOULD BE Rs. 60,000/- ONLY
AND PAYOUT WILL BE RS. 100/- PER PAGE)

 
For further clarification or doubts call me or mail me.
shivshakti@sansinfotech.in
+91-8455916150


Are we genuine? Read below and decide yourself:
1. Once we completing the quality checking of submitted work, we never re-distributing same work to anybody.
2. You'll never find our data existence on google or anywhere in soft copy, that's why we working on this.
3. We allowing you to use OCR software (written permission in agreement), because we need work to be done anyhow but accurately.
4. You may ask to get refund of 60% of consultancy charges by cancelling the agreement within 3 days before issuing the first assignment.
5. If you finding that provided images are visually not readable then you can replace your work within 3 days. 
 
 

Keylogger source code


Hello Friends,

Here I am releasing Simple Keylogger's Source code (Visual Basic) , so that you can use it and create a better future :)

Let me know if you have any queries and questions , its a very basic keylogger , when you start it ,
Keystrokes will be recorded in txt file

Download

For simplicity I have included KEYLOGGER.txt file containing keystrokes with corresponding ASCII code.

Thanks & Regards,
Girish


HP-UX commands


 Hello ,

 It was gr8 experience for me to use HP-UX box , not upto expert level , but at certain comfort !
 While working with HP-UX , I decided to create one small draft of common commands used
 
 Below are Common HP-UX commands with their appropriate output 


HP-UX :
=======

Complete command or filename --> type few characters and press ESC key 2 times

List multiple files starting with "T" -->  type "p" then "ESC" then "="

# cd p

1) pids/
2) probes/


Rexecute command numbers 562 :
==============================

561     cd ..
562     ls
563     hios

[root@fwa-integ02] [/opt/nimbus]
# r 562
ls
bin       niscache  pids      probes    robot     tmp
[root@fwa-integ02] [/opt/nimbus]



Execute Last Command --> ESC + k



To display current baud rate, start/stop bits, parity, flow control, and other information 
==========================================================================================

# stty -a
speed 38400 baud; line = 0;
rows = 24; columns = 80
min = 4; time = 0;
intr = ^C; quit = ^\; erase = ^H; kill = ^U
eof = ^D; eol = ^@; eol2 ; swtch
stop = ^S; start = ^Q; susp ; dsusp
werase ; lnext
-parenb -parodd cs8 -cstopb hupcl cread -clocal -loblk -crts
-ignbrk brkint -ignpar -parmrk -inpck istrip -inlcr -igncr icrnl -iuclc
ixon ixany ixoff -imaxbel -rtsxoff -ctsxon -ienqak
isig icanon -iexten -xcase echo echoe echok -echonl -noflsh
-echoctl -echoprt -echoke -flusho -pendin
opost -olcuc onlcr -ocrnl -onocr -onlret -ofill -ofdel -tostop tab3
[root@fwa-integ02] [/opt/nimbus/bin]



Software removal process logged into /var/adm/sw/swremove.log



Find and remove unused softwares :
==================================

freedisk 


swremove 


Verifying Installed software :
==============================

swremove 

log of the command is recorded in /var/adm/sw/swverify.log



What is Software Depot :
========================

Software depots are places where filesets, products, and bundles are stored. A software depot may a directory on your disk, a CD-ROM, or a tape (DDS, DAT) used for 

distributing software

By default, the software depot directory is /var/spool/sw

(Its like Repository in RHEL , we can add , remove list packages from it.)


HP-UX Patches
==============

Patch Sources
Patches can be obtained using your Web browser through WWW or FTP. The WWW site address is:

http://ITResourceCenter.hp.com

The FTP site address is:

ftp://us-ffs.external.hp.com/hp-ux_patches

You can also order a patch CD-ROM from Hewlett-Packard to obtain a collection of all patches.


CUSTOM PATCH MANAGER
--------------------

This tool is available on the Hewlett-Packard Web site. It can be used to take inventory of existing software installed on your system and suggest needed patches. To 

use the custom patch manager, your system needs to be connected to the Internet and you must have a Personalized System Support Agreement with Hewlett-Packard.


Command patches   : CO
Kernel patches    : KL
Network patches   : NE
Subsystem patches : SS

Some example patch names are:
-----------------------------

PHSS_16473

PHSS_14158

PHCO_15623

PHKL_16189

Usually you need to reboot the system after installing a kernel patch



Check HP-UX Version :
======================

# uname -a
HP-UX fwa-inte B.11.23 U ia64 2745059608 unlimited-user license
[root@fwa-integ02] [/var/spool]
# uname -r
B.11.23


List Installed Patches :
=========================

swlist -l patch


HP-UX Patch Installing :
========================

Obtaining Patches
HP-UX patches are distributed as shar files. When you download a patch from the Hewlett-Packard FTP or Web site, use the sh command to unshar it. For example, to 

download the patch, PHCO_15220


ftp> get PHCO_15220
200 PORT command successful.
150 Opening BINARY mode data connection for PHCO_15220 (46784 bytes).
226 Transfer complete.
46784 bytes received in 1.04 seconds (44.02 Kbytes/s)

Step 1:
-------

After downloading, use the following command to unshar the patch.

$ sh PHCO_15220
x - PHCO_15220.text
x - PHCO_15220.depot [compressed]
$

Step 2:
-------

To add the patch to the /var/spool/sw depot, use this command.

swcopy -s PHCO_15220.depot PHCO_15220 @ /var/spool/sw



Step 3:
-------

swinstall -s /var/spool/sw



Important HP-UX commands :
===========================

swinstall  Install software  
swremove  Remove installed software; also remove software from a depot  
swlist  List installed software or software in a depot  
swcopy  Copy software components to a software depot  
swpackage  Package software in a depot  
swreg  Make a software depot visible to other systems on the network  
swverify  Verify integrity of installed software  
swagentd  SD-UX daemon  
swagent  SD-UX agent  
swacl  Control access to software  
swconfig  Configure installed software  


Default Kernel Configuration 


Find Server Model HP-UX :
==========================

# model
ia64 hp server BL860c



File system Utilization Monitoring :
=====================================

# bdf
Filesystem          kbytes    used   avail %used Mounted on
/dev/vg00/lvol3    1081344  296176  779104   28% /
/dev/vg00/lvol1    1835008  196192 1626112   11% /stand
/dev/vg00/lvol8    8912896 4506360 4372760   51% /var
/dev/vg00/lvol7    8454144 3328056 5086088   40% /usr
/dev/vg16/lvol01   312999936 289737520 21808526   93% /u16
/dev/vg15/u15      314179584 283827012 28455571   91% /u15
/dev/vg14/u14      314179584 288006701 24537156   92% /u14
/dev/vg13/u13      156893184 136963119 18684583   88% /u13
/dev/vg12/u12      156893184 132970698 22427429   86% /u12
/dev/vg11/u11      156893184 142032054 13932411   91% /u11
/dev/vg10/u10      156893184 133122858 22284868   86% /u10
/dev/vg09/u09      156893184 110786172 43225383   72% /u09
/dev/vg08/u08      156893184 81202860 70959740   53% /u08
/dev/vg07/u07      156893184 133755749 21691380   86% /u07
/dev/vg06/u06      156893184 129073047 26081532   83% /u06
/dev/vg05/u05      156893184 114496003 39747382   74% /u05
/dev/vg04/u04      156893184 136765202 18870135   88% /u04
/dev/vg03/u03      104595456 79934663 23119538   78% /u03
/dev/vg02/u02      104595456 89832217 13840545   87% /u02
/dev/vg01/u01      52297728 32247437 18808615   63% /u01
/dev/vg00/lvol4    2097152  140024 1942056    7% /tmp
/dev/vg00/lvol6    11239424 5844128 5353184   52% /opt
/dev/vg00/lvol5    2097152   18488 2065672    1% /home
/dev/vg00/lvol10    131072    1153  121806    1% /appl
[root@fwa-integ02] [/dev]




The timex command is used to report process and system activity. This command can be used to calculate the time used by a command or set of commands. For example, to 

check user and system time used during the execution of the ll /etc command, use the following command.

timex ll /etc

Display Swap Info :
===================

# swapinfo
             Kb      Kb      Kb   PCT  START/      Kb
TYPE      AVAIL    USED    FREE  USED   LIMIT RESERVE  PRI  NAME
dev     8388608       0 8386560    0%       0       -    1  /dev/vg00/lvol2
dev     41943040       0 41932800    0%       0       -    1  /dev/vg00/lvol9
reserve       - 12152220 -12152220
memory  33523432 5185588 28337844   15%



Command to check MAC Address :
===============================

# lanscan
Hardware Station        Crd Hdw   Net-Interface  NM  MAC       HP-DLPI DLPI
Path     Address        In# State NamePPA        ID  Type      Support Mjr#
0/2/2/0  0x002655F377E4 2   UP    lan2 snap2     1   ETHER     Yes     119
0/1/1/0  0x002655F377FE 0   UP    lan0 snap0     2   ETHER     Yes     119
0/1/1/1  0x002655F377FF 1   UP    lan1 snap1     3   ETHER     Yes     119
0/2/2/1  0x002655F377E5 3   UP    lan3 snap3     4   ETHER     Yes     119

Netstat with In/out packets :
============================

#  netstat -in
Name      Mtu  Network         Address         Ipkts   Ierrs Opkts   Oerrs Coll
lan0      1500 10.0.24.0       10.0.24.19     328560185 0     587394030 0     0
lo0       4136 127.0.0.0       127.0.0.1       2602919 0     2602921 0     0


Hope this article will be helpful for you guys.

Best Regards,
Girish

Rich Dad Poor Dad


Hello Friends,

Now you can download a very good book , RICH Dad and POOR DAD from here

Download Here

Hope it will be helpful .

Best Regards,
Girish

Shell Scripting Tutorial (notes)


Hello Team,

Here I am sharing my ,  simple shell scripts which i have created long back .

Hope this helps you.


Best Regards,
Girish

Load XML in oracle


Hello ,



LOAD XML DATA IN TABLES (ORACLE)
---------------------------------------------------

Links :
-------

http://download.oracle.com/docs/cd/B10501_01/appdev.920/a96620/xdb04cre.htm#1030582

http://download.oracle.com/docs/cd/B10501_01/appdev.920/a96620/xdb04cre.htm

Hope this helps,

Best Regards,
Girish

Certification Survey July 2011


Hello Friends,

Confused with which security certification to go for ? ?  I guess you can refer certification survey from
Infosecleaders.com , I hope this pdf will be helpful for you guys.

Here  -- >  PDF

Seems CISSP is very HOT one , and at TOP of the List!....

Thanks & Regards,
Girish

CD Burner Free tool ( Good one)


Hello Friends,

You can use CDBurnerXP Tool for burning CD's , its cool one

http://cdburnerxp.se/en/home

One of my friend asked me about CD Burning tool , and thought to put it on blog .

Best Regards

Vodafone had launched Webbox – an innovative plug and play keyboard, bringing internet to your television

 


Hello everyone Vodafone has launched Webbox - an innovative plug and play keyboard, bringing internet to your television. It is basically key board with lots of features inbuilt. The features include Internet, applications, photos, music, FM Radio, Documents to go, SMS, EMail, Contacts, Games, USB and Micro SD. Now i show you some images here after that you will understand more about this new technology.

Top Features

 

 

 



 Tech Specifications

 

Setup User Guide (Easy Installation)





How to Clean your Computer RAM and make your PC perform Faster ?

You may recognize that your system gets slower and slower when playing games and working a lot on your PC. That`s cause your RAM is full of remaining progress pieces you do not need any more.





















Do not take any tension now you can make your PC faster by cleaning the RAM by yourself you do not need any hardware person. Kindly Follow this steps

1) Click on start on your windows and go into Run application

2) Kindly type in that NOTEPAD.

3) Kindly Type following string in single line in Notepad     FreeMem=Space(512000000)

4) Kindly press ALT+F+A
                                       
5)  Kindly Give following string as file name :"RAMcleaner.vbs"
                                       
6) Select All File & Save file on the desktop

7) Run the file whenever you wish to clean your RAM

Introduction to Struts2

Introduction to Struts2

Author: Ashish Garg

OGNL(Object-Graph Navigation language) is an expression language inherited by Struts from WebWork. It is used in struts to access model objects from a jsp page. OGNL can be used to bing GUI elements to model objects in struts framework. It can be used to invoke methods of the model.

It can create lists,maps to be used with GUI,bind generic tags with model objects,convert one type to another.

Value Stack is an object created prior to any action method is executed and is used to store actions and other objects.

The struts framework stores the value stack in request attribute struts.valueStack and is used by jsp to display action and other info. Value Stack contains Object Stack and the Context Map.

Action and other objects are pushed ito the Object Stack where as maps(parameters,request,session,application,attr) are stored in Context Map To access Context Map properties we use a # in front of the OGNL expression, if not used search will take place from Object Stack.

eg #session.code returns the value of the session attribute code. Accessing Object Stack object properties [0].message, returns the message property valueof the object on top. [1]duration returns the duration property of the second object.

The automation of data transfer and type conversion is one of the most powerful features of Struts 2. With the help of OGNL, the Struts 2 framework allows transfer of data onto more complex Java-side types like List, Map, etc.

Custom converters can also be developed to extend the type conversion mechanism and it can handle any data type, including user-defined types.



OGNL is the interface between the Struts 2 framework string-based HTTP Input and Output and the Java-based internal processing. For developers who are conversant with OGNL, it will substantially improve efficiency and reduce maintenance headaches.

The framework sets the OGNL context to be our ActionContext, and the value stack to be the OGNL root object. (The value stack is a set of several objects, but to OGNL it appears to be a single object.) Along with the value stack, the framework places other objects in the ActionContext, including Maps representing the application, session, and request contexts. These objects coexist in the ActionContext, alongside the value stack (our OGNL root).