aspose file tools*
The moose likes Sockets and Internet Protocols and the fly likes API's Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Sockets and Internet Protocols
Bookmark "API Watch "API New topic
Author

API's

Angela Jessi
Ranch Hand

Joined: Nov 27, 2000
Posts: 428
Hi,
I am very new to API. I want to know how to create it menas which are basic steps I have to concern?

Thanks in advance,
Angela
Anonymous
Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
API stands for Application Programming Interface. Java API's are usually created by Sun and used by the rest of us. Which API are you interested in?
Angela Jessi
Ranch Hand

Joined: Nov 27, 2000
Posts: 428
Thanks Bodie,
I want to make Socket API and GUI API. Please give me suggestion how to start and if any examples you have.
Thanks again,
Angela
Originally posted by Bodie Minster:
API stands for Application Programming Interface. Java API's are usually created by Sun and used by the rest of us. Which API are you interested in?

Anonymous
Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
You mean you want to build a standalone GUI application using Java? And you want to make use of the Socket API in that application?
Let's start with the GUI application. You could build a simple JFrame with a button in it. When you can get it to show up on screen the way you expect it to, you can make it do something a little more interesting.
This will involve creating a custom class that extends JFrame. You will need to pick a layout manager. I like GridBagLayout, but it is very complex for just a single button. Probably FlowLayout would suffice for this application. Once you have that all set up, create an instance of a JButton and add it to your JFrame. Then pack and show the application.
Angela Jessi
Ranch Hand

Joined: Nov 27, 2000
Posts: 428
Thanks again Bodie,
What my project is:
We are developing Client-Server programs.
We already develope Socket Layer which send/Receive some string.
Now We want to write some function (means SocketAPI) through with we can set/Get the values from the server with push mechanism. That values when We get from server with function GET VALUES(API), we want to put into appropriate GUI's. For this we want to some marshling and demarshling for request message to get the value. FOR ALL THIS PURPOSE I HAVE TO WRITE SOME API on Client side using Java.I don't know what is marshling and demarshling? If I know i have to make API set for this.
Would you please help me out in this,
Thanks again,
Angela
Anonymous
Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
Sorry, but I've never heard of marshaling and demarshaling.
Marcela Blei
Ranch Hand

Joined: Jun 28, 2000
Posts: 477
Angela: Are you talking about the use of RMI?
Art Metzer
Ranch Hand

Joined: Oct 31, 2000
Posts: 241
According to Ed Roman, in his book Mastering Enterprise JavaBeans,
"[W]hat if the target machine represents data differently than the way you represent data? For example, what happens if one machine uses a different binary standard to represent numbers?....Marshalling and unmarshalling is the process of massaging parameters so that they are usable on the machine being invoked on remotely. It is the packaging and unpackaging of parameters so that they are usable in two heterogeneous environments." (p. 506, Appendix A, "Understanding Java Remote Method Invocation (RMI)".)
Hope this helps,
Art
Angela Jessi
Ranch Hand

Joined: Nov 27, 2000
Posts: 428
Thanks everyone...
I want to develop SOCKET API's like openSocket(), sendSocket(), receiveSocket(),TCPSocket()
i will appreciate help,
Thanks
angela
Neeraj Thakkar
Ranch Hand

Joined: Dec 06, 2000
Posts: 80
Hi Angela,
API as alredy specified stands for Application Programming Interface. These are usually supplied by the builder or creator of languages for the developers to build their own programs or softwares. Like JDK1.2 API is provided by Sun Micriosystems for the programmers to build their own Softwares.
So, API in itself is a very big thing.
I think u r getting confused. You actually wish to develop a client side program which does all that u wrote and for that you will be using the API's provided by Sun Microsystems.


Neeraj Thakkar<br />"Try to get what you like,Else you will be forced to like what you get."
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: API's
 
Similar Threads
Posting to bump up my count...
The x900 effect ?
Cant use object from another class
WA #1.....word association
Text box value is not being completely filled with request attribute