Poster | Thread |
Hypex
| |
Re: What's with all these program needing WGet? Posted on 29-Feb-2012 14:59:45
| | [ #41 ] |
|
|
|
Elite Member |
Joined: 6-May-2007 Posts: 11180
From: Greensborough, Australia | | |
|
| @Xenic
Quote:
Why load a library just to call one simple function in that library instead of spending the day duplicating the function in your own code? |
Because using the library would mean less time! If only one function is used then it suits its purpose.
Quote:
Why would you use datatyes to play a sound when you can use ahi directly? |
Because once you know how to program it datatypes is a lot easier then using AHI! And AHI is backwards, the library is low level and the device high level. In any case it's a lot easier using dayatypes to load and play a sound that using AHI.
Case in point: I was porting a sound player over to AHI. With the hours it took to convert audio.device to AHI including the bufferng routines I had duplicated the process with datatyoews in much less time!
I can see this is missing the point but you did mention library.
Quote:
Does that include 3rd party SOBJs? They all get loaded external to the main program. |
As with libraries, any third party SOBJS should be included with the program.
Quote:
I found it outside of the SDK on the Workbench. But it doesn't say how to program TCP.
Quote:
Loading WGet every time the Internet is checked would be unnecessary if OS4 included a reentrant (pure) version of WGet or Curl (or similar command) that could be made "RESIDENT" using the Resident command in the startup-sequence. |
Sure but it's still an external command. |
|
Status: Offline |
|
|
Hypex
| |
Re: What's with all these program needing WGet? Posted on 29-Feb-2012 15:02:03
| | [ #42 ] |
|
|
|
Elite Member |
Joined: 6-May-2007 Posts: 11180
From: Greensborough, Australia | | |
|
| @Chris_Y
Quote:
A library version would be something completely different, for a start you'd lose the ease of just opening and reading files. For example, in ARexx with http-handler you can do this to show a file: |
I see your point. Of course, if HTTP-Handler were part of the OS this would be easier to deal with. |
|
Status: Offline |
|
|
Hypex
| |
Re: What's with all these program needing WGet? Posted on 29-Feb-2012 15:09:33
| | [ #43 ] |
|
|
|
Elite Member |
Joined: 6-May-2007 Posts: 11180
From: Greensborough, Australia | | |
|
| @Tomas
Quote:
Why go through the trouble of coding something twice when you can just use wget which works very well for this purpose? |
Because that is missing the point. Let me lay it on the line. WGet is a CLI command, An executable binary should not be using a CLI command to perform a function such as reading data off a medium. That makes it looks sloppy and unprofessional. Only in isolated cases should a CLI command be called.
What should be done is to use a static or shared library.
Quote:
But i guess you rather want the little developing resources we have be wasted on this instead |
No, I want those resources to be used properly. |
|
Status: Offline |
|
|
Hypex
| |
Re: What's with all these program needing WGet? Posted on 29-Feb-2012 15:10:53
| | [ #44 ] |
|
|
|
Elite Member |
Joined: 6-May-2007 Posts: 11180
From: Greensborough, Australia | | |
|
| @salass00
Quote:
I'm surprised no-one else has mentioned it yet, but there is also Chris Young's excellent http-handler: |
I thought Chris already had. |
|
Status: Offline |
|
|
Hypex
| |
Re: What's with all these program needing WGet? Posted on 29-Feb-2012 15:17:10
| | [ #45 ] |
|
|
|
Elite Member |
Joined: 6-May-2007 Posts: 11180
From: Greensborough, Australia | | |
|
| @Arko
Quote:
Because nothing like this is available under C: |
I don't want anything used from C: in this case.
Quote:
You are asking every program inluding its own wget implementation, most programmers are glad if they can use something ready. |
What is being used is intended for shell scripts and CLI. Not for programs. |
|
Status: Offline |
|
|
Hypex
| |
Re: What's with all these program needing WGet? Posted on 29-Feb-2012 15:19:20
| | [ #46 ] |
|
|
|
Elite Member |
Joined: 6-May-2007 Posts: 11180
From: Greensborough, Australia | | |
|
| @djrikki
'Quote:
I too share the opinion of Olsen who explains all very clearly. Why reinvent the wheel? If there are tried-and-tested tools out there already then no-one should be afraid to use them in their own developments. |
Tried and tested tools, yes. Not tried and tested functiions to be used "inside" programs. |
|
Status: Offline |
|
|
Hypex
| |
Re: What's with all these program needing WGet? Posted on 29-Feb-2012 15:22:03
| | [ #47 ] |
|
|
|
Elite Member |
Joined: 6-May-2007 Posts: 11180
From: Greensborough, Australia | | |
|
| @Fab
Quote:
I don't think calling an external command from a program is very elegant, actually (especially if the said command not integrated in the OS and that various versions are available). For scripts, it's another matter, of course, nothing wrong there. |
Thankyou! Finally someone who gets the point. And with whom I agree with. |
|
Status: Offline |
|
|