Performs the desired Conversion.

        :param request: The webob Request object describing the
                        request.
        :param response: The webob Response object describing the
                         response.
        :param data: The data dictionary returned by the prepare()
                     method.

        :returns: A string, the results of which are the desired
                  conversion.

def convert(self, request, response, data):
        """
        Performs the desired Conversion.

        :param request: The webob Request object describing the
                        request.
        :param response: The webob Response object describing the
                         response.
        :param data: The data dictionary returned by the prepare()
                     method.

        :returns: A string, the results of which are the desired
                  conversion.
        """

        if self.modifier.param in (None, 'canonical', 'local'):
            return str(request.environ['SERVER_PORT'])
        elif self.modifier.param == 'remote':
            return str(request.environ.get('REMOTE_PORT', '-'))

        return "-"