def expose_plugview(url='/'):
 def wrap(v):
  handler = expose(url, v.methods)
  if hasattr(v, 'as_view'):
   return handler(v.as_view(v.__name__))
  else:
   return handler(v)
 return wrap

def expose_plugview ( url = '/' ) : def wrap ( v ) : handler = expose ( url , v . methods ) if hasattr ( v , 'as_view' ) : return handler ( v . as_view ( v . __name__ ) ) else : return handler ( v ) return wrap
decorator to expose flasks pluggable view classes .