Wednesday, 9 November 2016
Wednesday, 24 August 2016
Unix Shell Scripting (day 2)
Shell Scripting:
Command for command
1.creating text file with some text cat > text_file_name
Note:To end the above created text document press ctrl+d on ur key board.
2.To view the content of the text file cat < text_file_name
3.To merge the content of 2 different
files into another file cat file_name_1 file_name_2 > file_name_3
4.renaming a file mv Old_file_name New_file_name
5.removing a file rm file_name
6.removing a directory rm -r directory_name
7.removing a directory rmdir directory_name
8.to copy a existing file from one place to another cp file_name1 folder_name/file_name2
Note: Copying a "file name1" existed in home folder into a folder_name "music" with name "file name2"
9.to create a link between two files(replica) ln file_name_1 file_name_2
Note:In 9th command whatever the changes made in file_name_1 it reflected in file_name_2
10.to create a soft link for the hard link ln -s file1 file2
Note :In 10nth command file1 is hard link and file2 is soft link. it will not reflect anything to hard
link when we remove the soft link. If we remove the hard link then soft link will not open since hard link of it was not exist.
Command for command
1.creating text file with some text cat > text_file_name
Note:To end the above created text document press ctrl+d on ur key board.
2.To view the content of the text file cat < text_file_name
3.To merge the content of 2 different
files into another file cat file_name_1 file_name_2 > file_name_3
4.renaming a file mv Old_file_name New_file_name
5.removing a file rm file_name
6.removing a directory rm -r directory_name
7.removing a directory rmdir directory_name
8.to copy a existing file from one place to another cp file_name1 folder_name/file_name2
Note: Copying a "file name1" existed in home folder into a folder_name "music" with name "file name2"
9.to create a link between two files(replica) ln file_name_1 file_name_2
Note:In 9th command whatever the changes made in file_name_1 it reflected in file_name_2
10.to create a soft link for the hard link ln -s file1 file2
Note :In 10nth command file1 is hard link and file2 is soft link. it will not reflect anything to hard
link when we remove the soft link. If we remove the hard link then soft link will not open since hard link of it was not exist.
Unix Shell Scripting(day 1)
Shell Scripting:
All Unix Commands should be in Lower Case only
Command for command
1.The time at which i login - who am i
2.present working directory - pwd
3.present calender - cal
4.calender of a particular date - cal 7 2009
cal feb 2003
5.current date - date
6.customized date - date '+DATE:%m-%y%nTIME:%H:%M:%S'
7.creating empty text files - touch text_file_name1,...
8.creating directories - mkdir directory_name
9.folder inside a folder - mkdir existingfolder_name/new folder_name
10.change directory from one to another - cd directory name
All Unix Commands should be in Lower Case only
Command for command
1.The time at which i login - who am i
2.present working directory - pwd
3.present calender - cal
4.calender of a particular date - cal 7 2009
cal feb 2003
5.current date - date
6.customized date - date '+DATE:%m-%y%nTIME:%H:%M:%S'
7.creating empty text files - touch text_file_name1,...
8.creating directories - mkdir directory_name
9.folder inside a folder - mkdir existingfolder_name/new folder_name
10.change directory from one to another - cd directory name
Monday, 22 August 2016
SWIFT Messages in Banking
SWIFT stands "Society for WorldWide Interbank Financial Telecommunication".
It is a messaging network that financial institutions use to securely transmit information and instructions through a standardized system of codes.
Swift assigns each financial organization a unicode that has either 8 characters or 11 characters.
The code is called Interchangeably the Bank Identifier Code(BIC),Swift Code,Swift ID or ISO 9362.
Example for SWIFT code:
UNCRITMM it is a swift code for ITALIAN bank UniCredit Banca head quartered in Milan.
The first four characters UNCR in above swift code represents the bank code
The Next two letters IT represents country code
The next two letters MM represents the Location/City Mode
If you want to know structure of the swift message in detail it is explained in below link
http://www.sepaforcorporates.com/swift-for-corporates/read-swift-message-structure/
It is a messaging network that financial institutions use to securely transmit information and instructions through a standardized system of codes.
Swift assigns each financial organization a unicode that has either 8 characters or 11 characters.
The code is called Interchangeably the Bank Identifier Code(BIC),Swift Code,Swift ID or ISO 9362.
Example for SWIFT code:
UNCRITMM it is a swift code for ITALIAN bank UniCredit Banca head quartered in Milan.
The first four characters UNCR in above swift code represents the bank code
The Next two letters IT represents country code
The next two letters MM represents the Location/City Mode
If you want to know structure of the swift message in detail it is explained in below link
http://www.sepaforcorporates.com/swift-for-corporates/read-swift-message-structure/
instanceof VS isInstance()
instanceof vs isInstance():
instanceof: It is used to find the Object is a particular type or not .
Example:
Thread t=new Thread();
System.out.println(t instanceof Runnable);
In above example we know particular type i.e., Runnable,we are checking whether the given object 't' is Runnable type or not.
isInstance(): when we don't know the particular type at starting to check whether the given object is of particular type or not. For this we have to check the type of the given object dynamically at run time as shown below example
Example:
class Test {
public static void main(String args) throws Exception{
Thread t=new Thread();
System.out.println(Class.forName(args[0]).isInstance(t));
}
}
output:
java Test java.lang.Runnable
o/p:true
java Test String
o/p:false
instanceof: It is used to find the Object is a particular type or not .
Example:
Thread t=new Thread();
System.out.println(t instanceof Runnable);
In above example we know particular type i.e., Runnable,we are checking whether the given object 't' is Runnable type or not.
isInstance(): when we don't know the particular type at starting to check whether the given object is of particular type or not. For this we have to check the type of the given object dynamically at run time as shown below example
Example:
class Test {
public static void main(String args) throws Exception{
Thread t=new Thread();
System.out.println(Class.forName(args[0]).isInstance(t));
}
}
output:
java Test java.lang.Runnable
o/p:true
java Test String
o/p:false
Coding Standards for Listeners
Listeners:
Listener listens the event and perform action according to the Event.
Q)How to register a Listener?
A) public void addMyActionListener(MyActionListener l)
1.The prefix for method name should be add
2.The parameter passing in the method should be same as method name without prefix 'add'.
Q)How to unregister a Listener?
A)public void removeMyActionListener(MyActionListener l)
1.The prefix for method name should be 'remove'
2.The parameter passing in the method should be same as method name without prefix 'remove'.
Listener listens the event and perform action according to the Event.
Q)How to register a Listener?
A) public void addMyActionListener(MyActionListener l)
1.The prefix for method name should be add
2.The parameter passing in the method should be same as method name without prefix 'add'.
Q)How to unregister a Listener?
A)public void removeMyActionListener(MyActionListener l)
1.The prefix for method name should be 'remove'
2.The parameter passing in the method should be same as method name without prefix 'remove'.
Coding standards for EJB
EJB:
It means 'Enterprise Java Bean'
Bean is a simple Java class contains private variables and setters,getters for all the private variables.
Example:
public class StudentBean {
private String name;
private boolean empty;
public void setName(String name) {
this.name=name;
}
public String getName() {
return name;
}
public boolean getEmpty()/isEmpty {
return empty;
}
It means 'Enterprise Java Bean'
Bean is a simple Java class contains private variables and setters,getters for all the private variables.
Example:
public class StudentBean {
private String name;
private boolean empty;
public void setName(String name) {
this.name=name;
}
public String getName() {
return name;
}
public boolean getEmpty()/isEmpty {
return empty;
}
Thursday, 18 August 2016
Subscribe to:
Posts (Atom)