@classmethod<EOL><INDENT>def _wrap(cls, func):<DEDENT>
if isinstance(func, cls):<EOL><INDENT>return func<EOL><DEDENT>return functools.update_wrapper(cls(func), func)<EOL>
Ensures that the function is wrapped in a ScriptAdaptor
object.  If it is not, a new ScriptAdaptor will be returned.
If it is, the ScriptAdaptor is returned.

:param func: The function to be wrapped.