<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def locateChild(self, context, segments):
 """ Delegate child lookup to the wrapped resource but wrap whatever results in another instance of this wrapper. """

        childDeferred = maybeDeferred(
            self.wrappedResource.locateChild, context, segments)
        def childLocated((resource, segments)):
            if (resource, segments) == NotFound:
                return NotFound
            return _SecureWrapper(self.urlGenerator, resource), segments
        childDeferred.addCallback(childLocated)
        return childDeferred