N
Nemisis
Hi everyone,
As i have said before i am new to the 3-tier architecture and so far, i
have wrote quite a bit for both my DAL and BLL. Now one thing i want
to sort out is exceptions.
Should i just create an exception class within each layer? That way
the BLL, will know about the DALExceptions, GUI with know about BLL
etc. Or is it better to create a full exception library and include
that within the DAL (this doesnt sound right, but thought i would ask).
Many people dont seem to agree, but i thought, for example, if i had a
company and i needed to check that data before saving it, this would be
code for the BLL? Say the companyName had to be entered, else i was
not going to allow for the company to be saved. Am i right?
I would think this because, if i were to create another DAL, for xml
instead of SQL, i do not want to re-write all the checks again in both
DALs.
Thanks
As i have said before i am new to the 3-tier architecture and so far, i
have wrote quite a bit for both my DAL and BLL. Now one thing i want
to sort out is exceptions.
Should i just create an exception class within each layer? That way
the BLL, will know about the DALExceptions, GUI with know about BLL
etc. Or is it better to create a full exception library and include
that within the DAL (this doesnt sound right, but thought i would ask).
Many people dont seem to agree, but i thought, for example, if i had a
company and i needed to check that data before saving it, this would be
code for the BLL? Say the companyName had to be entered, else i was
not going to allow for the company to be saved. Am i right?
I would think this because, if i were to create another DAL, for xml
instead of SQL, i do not want to re-write all the checks again in both
DALs.
Thanks