• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Builder design pattern example

 
Siddharth Bhargava
Ranch Hand
Posts: 274
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
I am currently trying to understand the Builder design pattern. I am not able to understand its RTF text converter example. Please could anyone explain me the text converter example in java.

Thanks
 
Ilja Preuss
author
Sheriff
Posts: 14112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which text converter example?
 
Siddharth Bhargava
Ranch Hand
Posts: 274
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The RTF Text Format Converter example. RTF reader should be able to convert RTF to many text format. The example which is given in GoF book.
 
albert smith
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is a RTF example explained here:
http://www.oodesign.com/builder-pattern.html
 
Siddharth Bhargava
Ranch Hand
Posts: 274
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I had already seen this site. But here ASCIIText and Document have not been implemented. So its not that clear. If anywhere this example is complete in Java then please do provide me the same.
Also if there is any real world example of prototype pattern in Java then please do provide me that also.

Thanks in advance.
 
Jimmy Clark
Ranch Hand
Posts: 2187
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What don't you understand about the Builder design pattern?
[ October 15, 2008: Message edited by: James Clark ]
 
Siddharth Bhargava
Ranch Hand
Posts: 274
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I understood the builder design pattern but I was looking for a real time example of it so that I am able to understand the concept behind it.
Please provide me a real time (java code) example of builder design pattern so that I am able to understand the concept behind it through code. .
If possible please provide me the RTF format converter example (Complete java code). I saw the example in a website but the example was not complete.

Thanks in advance.
 
Ilja Preuss
author
Sheriff
Posts: 14112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Siddharth Bhargava:
I had already seen this site. But here ASCIIText and Document have not been implemented. So its not that clear.


I don't understand how those implementations are relevant to understanding the Builder pattern.
 
Jimmy Clark
Ranch Hand
Posts: 2187
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I understood the builder design pattern but I was looking for a real time example of it so that I am able to understand the concept behind it.


If you say that you understand the Builder pattern, then you surely understand the concepts of the pattern. It is a fairly simple design pattern, you should be able to implement it very easily.
 
Adeel Ansari
Ranch Hand
Posts: 2874
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check out wikipedia example.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic