logs archiveBotHelp.net / Freenode / #ada / 2015 / July / 17 / 9
charlie5
howdy nerdboy
bit -> not
Shark8: "could we write an exception-handler to [attempt to] reconnect?" ... i guess, but to wrap every remote call in an exception block would be pain
tbh, there may be an easier way
Visaoni
well, presumably you'd wrap something "lower" so the thing would attempt to reconnect itself
charlie5
dbotton talked about message queues to help avretthe prob
avert the
Visaoni
and you'd only see exceptions propogate into your code when something really went wrong and you were screwed
Shark8
Visaoni: charlie5: Agreed, you would want to put that logic "out of the way" not in the middle of everything... and you bring up a good point about DSA-config and implelmentation allowances.
charlie5
Visaoni: yup, you could keep a lot of the error coping out of the hands of the user]
i think it might be a good q' to bring up on comp.lang.ada ... "why are the pro's/con's of dsa" ... "why isn't is used more ?" ... "if not, why not ?"
why -> what
sparre: the reason i'm a little dsa-mad is that we tried to do something similar with ada83 ... seeing remote calls as part of the lang almost made me weep tears of joy :) ... now if only we can resolve the disconnect probs .. (unless the solution is dbotton's message queues)
Visaoni
don't message queues just turn it back into more of a socket-like thing?
charlie5
Visaoni: i've nto tried them, really ... i do something similar for sending msgs to physics and graphics engines
they are tasks
them being msg queuses
!quote
Allegra--
A new scientific truth does not triumph by convincing its opponents and making them see the light, but rather because its opponents die, and a new generation grows up that is familiar with it.
-- Max Planck
charlie5
glug ... that's probably the saddest thinking i've ever heard
... worse yet, if it's true
sparre
charlie5: It is true. Or at least quite close to being true.
I've seen it up close a few times by now.
charlie5: I like the idea of the DSA, but my view of where it is applicable doesn't quite match with the TCP based GNAT implementations of it.
charlie5
sparre: any thoughts n how droputs might be handled ?
on
if you have to implmenet msg queus, it sort of defeats the purpose ?
(Action) keenly awaits dbottons reply
i think jesselang and co are the main users/improvers of dsa
i guess my greatest worry is that after putting some effort into making code dsa-friendly, there is some fundmental flaw in dsa assumptions (as in assuming permanent faultless connections)
then again, the ada specs ppl are damned cluey ... can they have missed such probs ?
darkestkhan
Natacha: call of duty uses erlang?!
Natacha
that's what wikipedia says
(on server side)
and I can understand the value of hot updates when customers are as sensitive as dedicated gamers
I wonder how difficult it would be to write an Ada implementation with that kind of capability
sparre
charlie5: Only use dedicated connections. Support more different kinds of connections (I2C, SPI, etc.).
lamadasdas
hello
i'm gonna ask some stupid questions
since i'm confused
so
i want to create something like a "class"
sparre
Natacha: AdaCore has an example of hot updates to a running application.
lamadasdas
in ada this is called "package" ?
sparre
lamadasdas: No. A tagged type.
lamadasdas
uhm ah
type keyword? thats not it
that will allow me to make an object
sparre
charlie5: I don't know if GNAT supports heterogeneous DSA instances, but I consider that a must as well.
jk4
lamadasdas: you should try adacraft
lamadasdas
ok so how do i make a "class" ?:D
jk4
rather than muddling your way through
sparre
lamadasdas: What do you *actually* want to do?
jk4
try a tutorial
!adacraft
Allegra--
adacraft: AdaCraft or "Ada 95 : The art of object-oriented programming" is a useful tutorial for budding programmers by John English
or: http://faculty.cs.wwu.edu/reedyc/AdaResources/bookhtml/contents.htm
lamadasdas
ok
not found
sparre
type T is tagged null record;
jk4
internet..
lamadasdas
well i'm gonna do simple chat server as a hello world application
jk4
lamadasdas: http://www.adaic.org/resources/add_content/docs/craft/html/contents.htm
Ada is not like other OOP languages
there's no container called a class
lamadasdas
so now i want something like "ChatServer(Endpoint sh*t, someotherarguments args)" that i can instantiate
yes i know, i'm searching for something that can provide similiar functionality
or this isnt possible at all?
jk4
you're just going to end up writing C or Java in Ada
rather than writing idiomatic Ada
would suggest the tutorial
lamadasdas
ok i want ada
then how should i aproach this
i should defnitely NOT aproach this in OOP way?
jk4
tutorial will delay starting the project slightly, but will save you time afterward
we store data in records and perform operations on records
that's the gist of it
super gist
Natacha
whose idea was it to conflate 4 independent language features into the single "OOP" bundle?
jk4
part of four?
lamadasdas
ah, so "record" is term here
jk4
*shrug*
lamadasdas
thank you
i'll check that
jk4
public class Chat_Server { EndPoint s; public Chat_Server() { } }
may be represented in Ada as
type Chat_Server is record S : End_Point; end record;
Natacha
shouldn't you tag it?
oliver117
!last
jk4
not unless i have to
oop isn't a sink hole in Ada
you can elect to use it
Natacha
fair enough, but as far as the equivalency goes...
jk4
in java you can't make that choice
it's only there because of that consequence
function Create(S : End_Point) return Chat_Server;
something like that
shove it in a package
lamadasdas
can record contain procedures, some code that can be called?
« prev 1 2 3 4 5 6 7 8 9 10 11 next »