I saw the http example server in the CoreLibrary package, and instead I would like to know how to send an http request, for example to make a spider.
Debugging the application I've seen that sendReceiveObject(...) tries to send an HTMLPage object so I think it is not the right function to use.
Thanks.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Right now, the HTTPRequest object is used in server mode, so when a client browser connects, this request can be carried to whoever needs to deal with it.
I have long been planning to implement the client mode as well, so the code could be used to retrieve pages from the Internet (as a spider, as you say) - but have not had an excuse to spend time on it yet...
Would you be interested in helping me test and debug this, if I create this feature? I believe that I can create a first version within a few days - and you can then help me tune it to do exactly what you need it to do.
The first version would be able to retrieve pages by url string. When this is working, we can add POST functionality to support sending forms to websites.
Best,
Thor
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am thrilled to hear that you have been using the CoreLibrary, and I am even happier that you are improving the code. As you say, the CoreLibrary is very big and it has been used in many projects by now, but of course there are still many things that could be brushed up or expanded. The biggest problem is the documentation, of course, and I am hoping that this will increase over the coming months.
> I'm developing a program using the CoreLibrary, and now I need a feature to
> send command and receive binary data across a network (it could be also a lan,
> not only internet). I think about 2 solutions. The first solution could be the
> use of NetMessageProtocol with an object, derived from Object, attached to it.
> The latter (I prefer) consists of HTTP messages using POST and xml file for
> command and GET for data retrieval.
I would strongly consider using the NetMessageProtocol, as this supports binary objects in the messages. The most basic binary object is called DataSample, which holds the raw binary data using a char* and its size. The object Bitmap is directly inheriting from DataSample.
This is best for discrete messages, and if you want to work with streams of binary data (such as audio and video) you can use the MediaStreams in there, which are used for time series of high volume and frequency data.
> I also inserted a join functionality in the JThread class and if you think it
> is useful I'll post it to you.
That would be great! Which OS are you running on?
If you want to add objects to the CoreLibrary, you can do this two ways:
a) if your object is private to you or shouldn't be in the main CoreLibrary for some reason, you can expand your own thirdparty code. In here, you can put code, which you can copy in every time you download a new version of CoreLibrary. See corelibrary.sf.net for more info on this.
b) if your object is relevant to the CoreLibrary, meaning something you want to share with others and would be useful for others, just put it inside the CoreLibrary and send me the updates.
> I found CoreLibrary very powerful and I think you are making a great work. If
> I can, I would suggest you to insert a "what's new" file in the package.
I have just created a changelog.txt for the latest release, 1.0.6, which I will try to keep updated.
> Further,
> because the big number of functionality, an extended and update documentation
> was needed.
I completely agree with this and I am hoping to both do this myself, but also to have others help. Please send anything you want to see in there back to me.
Best,
Thor
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
thank you for your reply, I'm very interested in testing such objects.
I'm developing a program using the CoreLibrary, and now I need a feature to send command and receive binary data across a network (it could be also a lan, not only internet). I think about 2 solutions. The first solution could be the use of NetMessageProtocol with an object, derived from Object, attached to it. The latter (I prefer) consists of HTTP messages using POST and xml file for command and GET for data retrieval.
I also inserted a join functionality in the JThread class and if you think it is useful I'll post it to you.
I found CoreLibrary very powerful and I think you are making a great work. If I can, I would suggest you to insert a "what's new" file in the package. Further, because the big number of functionality, an extended and update documentation was needed.
Best,
Emiliano
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I saw the http example server in the CoreLibrary package, and instead I would like to know how to send an http request, for example to make a spider.
Debugging the application I've seen that sendReceiveObject(...) tries to send an HTMLPage object so I think it is not the right function to use.
Thanks.
Hi Emiliano,
Right now, the HTTPRequest object is used in server mode, so when a client browser connects, this request can be carried to whoever needs to deal with it.
I have long been planning to implement the client mode as well, so the code could be used to retrieve pages from the Internet (as a spider, as you say) - but have not had an excuse to spend time on it yet...
Would you be interested in helping me test and debug this, if I create this feature? I believe that I can create a first version within a few days - and you can then help me tune it to do exactly what you need it to do.
The first version would be able to retrieve pages by url string. When this is working, we can add POST functionality to support sending forms to websites.
Best,
Thor
Hi Emiliano,
I am thrilled to hear that you have been using the CoreLibrary, and I am even happier that you are improving the code. As you say, the CoreLibrary is very big and it has been used in many projects by now, but of course there are still many things that could be brushed up or expanded. The biggest problem is the documentation, of course, and I am hoping that this will increase over the coming months.
> I'm developing a program using the CoreLibrary, and now I need a feature to
> send command and receive binary data across a network (it could be also a lan,
> not only internet). I think about 2 solutions. The first solution could be the
> use of NetMessageProtocol with an object, derived from Object, attached to it.
> The latter (I prefer) consists of HTTP messages using POST and xml file for
> command and GET for data retrieval.
I would strongly consider using the NetMessageProtocol, as this supports binary objects in the messages. The most basic binary object is called DataSample, which holds the raw binary data using a char* and its size. The object Bitmap is directly inheriting from DataSample.
This is best for discrete messages, and if you want to work with streams of binary data (such as audio and video) you can use the MediaStreams in there, which are used for time series of high volume and frequency data.
> I also inserted a join functionality in the JThread class and if you think it
> is useful I'll post it to you.
That would be great! Which OS are you running on?
If you want to add objects to the CoreLibrary, you can do this two ways:
a) if your object is private to you or shouldn't be in the main CoreLibrary for some reason, you can expand your own thirdparty code. In here, you can put code, which you can copy in every time you download a new version of CoreLibrary. See corelibrary.sf.net for more info on this.
b) if your object is relevant to the CoreLibrary, meaning something you want to share with others and would be useful for others, just put it inside the CoreLibrary and send me the updates.
> I found CoreLibrary very powerful and I think you are making a great work. If
> I can, I would suggest you to insert a "what's new" file in the package.
I have just created a changelog.txt for the latest release, 1.0.6, which I will try to keep updated.
> Further,
> because the big number of functionality, an extended and update documentation
> was needed.
I completely agree with this and I am hoping to both do this myself, but also to have others help. Please send anything you want to see in there back to me.
Best,
Thor
Hi Thor,
thank you for your reply, I'm very interested in testing such objects.
I'm developing a program using the CoreLibrary, and now I need a feature to send command and receive binary data across a network (it could be also a lan, not only internet). I think about 2 solutions. The first solution could be the use of NetMessageProtocol with an object, derived from Object, attached to it. The latter (I prefer) consists of HTTP messages using POST and xml file for command and GET for data retrieval.
I also inserted a join functionality in the JThread class and if you think it is useful I'll post it to you.
I found CoreLibrary very powerful and I think you are making a great work. If I can, I would suggest you to insert a "what's new" file in the package. Further, because the big number of functionality, an extended and update documentation was needed.
Best,
Emiliano