Friday, January 8, 2010

OOP344 - assignment 2, fix bugs together

I tested our project today. There are still a lot of bugs in it. I realized the bugs needs the whole group work together to fix it, not only one person. For example, if the bug is at IO_Form, my part is IO_Edit, it doesn't mean I have to wait until IO_Form is fixed by the person who did that part, I also can fix it. Now it is too late for me to understand this. I hope my experience can give more people a help.

Wednesday, January 6, 2010

OOP344 - Assignment 2 about void(*_help)(messageStatus,IO_Form)

Here I got response from other group member - Ausley Lettroy Johnson.
Thanks.
------------------------------------------------------------------------------
RESOPNSE TO QUESTIONS BY FELLOW STUDENTS
Note: void(*_help)(messageStatus,IO_Form)
The above “_help” is a pointer to a function or logic that are passed the two arguments.
You use it like the following way:
(_Help)(ClearMessage, (*_owner));
Note: “*_owner” is a pointer to a form which controls all the fields and the fact that everything is done on a particular form, you have to be able to refer to it.
Note:”ClearMessage” is a value withing the enum list which is declared in iodef.
Note: The function logic has to be defined so that it processes the information passed to it. In this case, it gives a help message or clears the printed message at a particular location on the form. Help message might be date must be between a particular time.
Bool (*_Validate)((char*)_data.(*_owner));
Like help, this points to a logic that validates an entry. You also have to define the logic. What ever you want to validate that your form receives. The date etc.
You call it like above “_help” passing an address to the data entered and the form that is being used.

Question was: Do you initialize the pointer to the function logic? Yes
How:
bool (*Validate)(const char* , IO_Form&) = ((void(*)(MessageStatus, IO_Form&))(0))
Note: NO_FUNC is defined in iodef which initializes the “*Validate”
So you simply do within the class declaration
bool (*Validate)(const char* , IO_Form&) = NO_FUNC;
REMEMBER to include iodef.h.
Qusetion: How to use IO_Vedit display?
Ans: Since vedit inherits edit, you simply call the display of edit which is the working class. Vedit is simply for validation and for help messages. Therefore the arguments passed to vedit constructor must be passed onto edit and when you are requested to edit you do the following:
IO_Edit::edit();//The display code is within this function which makes editing possible.
Note: The pointer to data in iofield does not need dynamic memory allocation from within that class. It simply holds the address for location already allocated memory within ioedit. Therefor “IO_Field::_data = data.”


Hope it helps.

Thursday, December 31, 2009

OOP344 assignment 2 got help from other team

I checked other teams' wiki and found a lot of teams have already finished this assignment.
So I ask other team members who were doing the same part IO_Edit and IO_Vedit for help.
A lot of people replied me and I got a lot of help.
Here, I want to thank Ausley Lettroy Johnson, Anton Chan, Justin Robertson, Armin Kumarshellahand and Demosthenes Denny Papagiannidis. Especially Demosthenes Denny Papagiannidis.
I will tell this story to my team members who haven't finished the assignment to ask for help from other teams.

Monday, December 28, 2009

OOP344 - find a useful tool for tracking bugs.

Bite team introduced a useful tool for tracking bugs - https://bite.fogbugz.com/.
I checked it. It looks like a forum, but each column has special meaning, like case,title,status,opened by,remaining time,priority.
I can use it for my future projects.
for example: I'm testing a website functions. If I found a bug, I write it in the forum, I just continue writing. After several days, I come back to check if all those bugs are fixed or not. If it is fixed, I close it.
If I'm a programmer, I just login the forum, check each notes, fix them one by one, and leave response there.

OOP344 - use svn at seneca@york

If you don't bring a notebook to school everyday, and you want to use lab computer to do assignment2 or review oop344 notes, you need svn. But lab computers don't have svn.
I find a software called sharpsvn is very useful. No graphic interface, no need to install.
what I do is :
1. download the .7z file from my gmail account draft folder. (I just uploaded it to my web server, you can use 7-zip or winrar to unzip it. This one I used winrar to compress, about 8M. Because my web server don't know .7z files. If you use 7-zip to compress it again, it will be 4M.)
2. unzipped it to c:\temp for an example.
3. run cmd and in dos command type cd c:\temp\sharpsvn
4. type svn export svn://zenit.senecac.on.ca/oop344 c:\temp\oop344
5. type username and password
6. all files will be extract to c:\temp\oop344 folder
I use this way to review oop344 notes at school lab computers. It helped me a lot.
Hope it will help you too.

OOP344 - How do I use SVN at home

After using the svn, I found some difficulties when I update other person's files.
I may have changed something in other person's part. Other person may not agree that. After I did a SVN update, what I have wrote for other person's are gone.
What I'm doing now is:
1. make a copy of the svn folder.
2. I do everything in the copied folder.
3. After I have done the changes, I copy my part code to the svn folder, and do a submit on my part code only.
4. Then I do a SVN update, merge other person's code manully one by one to my copied folder.
5. Then I continue debug the project in the copied folder.
6. repeat from step 3 to 5 until the project finished.

Thursday, December 24, 2009

OOP344 Assignment 2

I'm working on IO_Edit and IO_Vedit.
IO_Vedit inherite IO_Edit.
How about those ~IO_Vedit(), IO_Vedit::display(), IO_Vedit::set(const void *str), IO_Vedit::editable() const? Do I need to write something there?
or just call ~IO_Edit(), IO_Edit::display(), IO_Edit::set(const void *str), IO_Edit::editable() const?
What do I need to do in void (*_Help)(MessageStatus, IO_Form&), bool (*_Validate)(const char*, IO_Form&)?
Thanks ahead.