Driver question

Martin J. Logan martin@REDACTED
Tue Aug 21 23:03:05 CEST 2001


Hello, I have two questions.
    I would like to do sone parsing of data. What is the best way to do this? I
have an integer and I would like to make sure that is is a particular length
and that it is comprised entirly of digits. I have looked at io_lib and a
number of other spots but havent really found anything too elegant.  Everything
seems to involve converting to strings or using large function gaurds. If this
is the way to go I will, but if anyone has a better idea I would like to know.
I am always parsing packets in erlang so any info on that in general would be
nice.

    I have an application running that emails the interested parties when it
goes down. I have accomplished this in a way that I think is rather kludgy. I
use a linked process that traps exit signals from my main supervisor. I was
wondering if there is a call back that is called during the shutdown sequence
of the app that I could use to make sure that the email is sent on the death of
the app.

    If anyone has nice solutions to either of these problems please let me
know.

       Cheers,
        Martin




More information about the erlang-questions mailing list