Code not tested but ....


#('title' 'text')

��� do: [:each |

��� ��� �� | body |

��� ��� ��� body := String new streamContents:

��� ��� ��� ��� ��� [ :s |

��� ��� ��� ��� ��� s nextPutAll: each ; cr; tab;

��� ��� ��� ��� ��� ��� nextPutAll:� '^ ';

��� ��� ��� ��� ��� ��� nextPutAll: each ; cr].

��� ��� ��� TBPost compile: body classified: 'accessing'

]


Le 2/5/16 � 17:35, Victor RENE a �crit�:
In the TinyBlog mini-project of the MOOC, we start by creating the model.
However, since I basically finished the exercises, I wanted to go one step further and
ask you guys, what is the correct way�_not_ to�write all gettters / setters for the fields.

TBPost >> title
��� ^ title
TBPost >> title: anObject
��� title := anObject
TBPost >> text
��� ^ text
TBPost >> text: anObject
��� text := anObject
etc...

Do you do it with macros / templates / something else�?
I am having a bit of�fun (although I would love that they unlock weeks 2 to 7 for me). Thanks in advance.

Victor RENE
Software engineer,
Game designer, Writer


tel: +33 6 26 83 61 76