• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 8. Zope Schemas and Forms > Schemas Versus Interfaces

Schemas Versus Interfaces

As mentioned earlier, schemas are just an extension to interfaces and therefore depend on the zope.interface package. Fields in schemas are equivalent to methods in interfaces. They are complementary to one other because they describe different aspects of an object. The methods of an interface describe the functionality of a component, and a schema's fields represent the state.

It is thus not necessary to develop a new syntax for writing schemas, and you can simply reuse the interface declaration:


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint