cleanup: remove double ## everywhere on documentation
This commit is contained in:
parent
3a7c2035ad
commit
d7c248b94e
15 changed files with 0 additions and 35 deletions
|
|
@ -1,5 +1,4 @@
|
|||
module DiasporaFederation
|
||||
##
|
||||
# Base-Controller for all DiasporaFederation-Controller
|
||||
class ApplicationController < ActionController::Base
|
||||
end
|
||||
|
|
|
|||
|
|
@ -1,10 +1,8 @@
|
|||
require_dependency "diaspora_federation/application_controller"
|
||||
|
||||
module DiasporaFederation
|
||||
##
|
||||
# this controller generates the hcard
|
||||
class HCardController < ApplicationController
|
||||
##
|
||||
# returns the hcard of the user
|
||||
#
|
||||
# GET /hcard/users/:guid
|
||||
|
|
|
|||
|
|
@ -1,12 +1,10 @@
|
|||
require_dependency "diaspora_federation/application_controller"
|
||||
|
||||
module DiasporaFederation
|
||||
##
|
||||
# this controller processes receiving messages
|
||||
class ReceiveController < ApplicationController
|
||||
before_action :check_for_xml
|
||||
|
||||
##
|
||||
# receives public messages
|
||||
#
|
||||
# POST /receive/public
|
||||
|
|
@ -16,7 +14,6 @@ module DiasporaFederation
|
|||
render nothing: true, status: :ok
|
||||
end
|
||||
|
||||
##
|
||||
# receives private messages for a user
|
||||
#
|
||||
# POST /receive/users/:guid
|
||||
|
|
|
|||
|
|
@ -1,10 +1,8 @@
|
|||
require_dependency "diaspora_federation/application_controller"
|
||||
|
||||
module DiasporaFederation
|
||||
##
|
||||
# this controller handles all webfinger-specific requests
|
||||
class WebfingerController < ApplicationController
|
||||
##
|
||||
# returns the host-meta xml
|
||||
#
|
||||
# example:
|
||||
|
|
@ -18,7 +16,6 @@ module DiasporaFederation
|
|||
render body: WebfingerController.host_meta_xml, content_type: "application/xrd+xml"
|
||||
end
|
||||
|
||||
##
|
||||
# @deprecated this is the pre RFC 7033 webfinger
|
||||
#
|
||||
# example:
|
||||
|
|
@ -46,7 +43,6 @@ module DiasporaFederation
|
|||
|
||||
private
|
||||
|
||||
##
|
||||
# creates the host-meta xml with the configured server_uri and caches it
|
||||
# @return [String] XML string
|
||||
def self.host_meta_xml
|
||||
|
|
|
|||
|
|
@ -2,13 +2,11 @@ require "diaspora_federation/logging"
|
|||
|
||||
require "diaspora_federation/web_finger"
|
||||
|
||||
##
|
||||
# diaspora* federation library
|
||||
module DiasporaFederation
|
||||
extend Logging
|
||||
|
||||
class << self
|
||||
##
|
||||
# the pod url
|
||||
#
|
||||
# @example with uri
|
||||
|
|
@ -17,7 +15,6 @@ module DiasporaFederation
|
|||
# config.server_uri = AppConfig.pod_uri
|
||||
attr_accessor :server_uri
|
||||
|
||||
##
|
||||
# the class to use as +Person+
|
||||
#
|
||||
# @example
|
||||
|
|
@ -95,7 +92,6 @@ module DiasporaFederation
|
|||
const_get(@person_class)
|
||||
end
|
||||
|
||||
##
|
||||
# configure the federation library
|
||||
#
|
||||
# DiasporaFederation.configure do |config|
|
||||
|
|
@ -105,7 +101,6 @@ module DiasporaFederation
|
|||
yield self
|
||||
end
|
||||
|
||||
##
|
||||
# validates if the engine is configured correctly
|
||||
#
|
||||
# called from after_initialize
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
module DiasporaFederation
|
||||
##
|
||||
# diaspora* federation rails engine
|
||||
class Engine < ::Rails::Engine
|
||||
isolate_namespace DiasporaFederation
|
||||
|
|
|
|||
|
|
@ -1,12 +1,10 @@
|
|||
module DiasporaFederation
|
||||
##
|
||||
# logging module for the diaspora federation
|
||||
#
|
||||
# it uses the logging-gem if available
|
||||
module Logging
|
||||
private
|
||||
|
||||
##
|
||||
# get the logger for this class
|
||||
#
|
||||
# use the logging-gem if available, else use a default logger
|
||||
|
|
|
|||
|
|
@ -3,7 +3,6 @@ require "diaspora_federation/engine"
|
|||
require "diaspora_federation"
|
||||
|
||||
module DiasporaFederation
|
||||
##
|
||||
# diaspora* federation rails engine
|
||||
module Rails
|
||||
end
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
module DiasporaFederation
|
||||
##
|
||||
# the gem version
|
||||
VERSION = "0.0.2"
|
||||
end
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
module DiasporaFederation
|
||||
##
|
||||
# This module provides the namespace for the various classes implementing
|
||||
# WebFinger and other protocols used for metadata discovery on remote servers
|
||||
# in the Diaspora* network.
|
||||
|
|
|
|||
|
|
@ -1,11 +1,9 @@
|
|||
module DiasporaFederation
|
||||
module WebFinger
|
||||
##
|
||||
# Raised, if the XML structure is invalid
|
||||
class InvalidDocument < RuntimeError
|
||||
end
|
||||
|
||||
##
|
||||
# Raised, if something is wrong with the webfinger data
|
||||
#
|
||||
# * if the +webfinger_url+ is missing or malformed in {HostMeta.from_base_url} or {HostMeta.from_xml}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
module DiasporaFederation
|
||||
module WebFinger
|
||||
##
|
||||
# This class provides the means of generating an parsing account data to and
|
||||
# from the hCard format.
|
||||
# hCard is based on +RFC 2426+ (vCard) which got superseded by +RFC 6350+.
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
|
||||
module DiasporaFederation
|
||||
module WebFinger
|
||||
##
|
||||
# Generates and parses Host Meta documents.
|
||||
#
|
||||
# This is a minimal implementation of the standard, only to the degree of what
|
||||
|
|
@ -23,7 +22,6 @@ module DiasporaFederation
|
|||
# URL fragment to append to the base URL
|
||||
WEBFINGER_SUFFIX = "webfinger?q={uri}"
|
||||
|
||||
##
|
||||
# Returns the WebFinger URL that was used to build this instance (either from
|
||||
# xml or by giving a base URL).
|
||||
# @return [String] WebFinger template URL
|
||||
|
|
@ -31,7 +29,6 @@ module DiasporaFederation
|
|||
@webfinger_url
|
||||
end
|
||||
|
||||
##
|
||||
# Produces the XML string for the Host Meta instance with a +Link+ element
|
||||
# containing the +webfinger_url+.
|
||||
# @return [String] XML string
|
||||
|
|
@ -43,7 +40,6 @@ module DiasporaFederation
|
|||
doc.to_xml
|
||||
end
|
||||
|
||||
##
|
||||
# Builds a new HostMeta instance and constructs the WebFinger URL from the
|
||||
# given base URL by appending HostMeta::WEBFINGER_SUFFIX.
|
||||
# @return [HostMeta]
|
||||
|
|
@ -60,7 +56,6 @@ module DiasporaFederation
|
|||
hm
|
||||
end
|
||||
|
||||
##
|
||||
# Reads the given Host Meta XML document string and populates the
|
||||
# +webfinger_url+.
|
||||
# @param [String] hostmeta_xml Host Meta XML string
|
||||
|
|
@ -77,7 +72,6 @@ module DiasporaFederation
|
|||
hm
|
||||
end
|
||||
|
||||
##
|
||||
# Applies some basic sanity-checking to the given URL
|
||||
# @param [String] url validation subject
|
||||
# @return [Boolean] validation result
|
||||
|
|
@ -86,7 +80,6 @@ module DiasporaFederation
|
|||
end
|
||||
private_class_method :webfinger_url_valid?
|
||||
|
||||
##
|
||||
# Gets the webfinger url from an XRD data structure
|
||||
# @param [Hash] data extracted data
|
||||
# @return [String] webfinger url
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
module DiasporaFederation
|
||||
module WebFinger
|
||||
##
|
||||
# The WebFinger document used for Diaspora* user discovery is based on an older
|
||||
# draft of the specification you can find in the wiki of the "webfinger" project
|
||||
# on {http://code.google.com/p/webfinger/wiki/WebFingerProtocol Google Code}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
module DiasporaFederation
|
||||
module WebFinger
|
||||
##
|
||||
# This class implements basic handling of XRD documents as far as it is
|
||||
# necessary in the context of the protocols used with Diaspora* federation.
|
||||
#
|
||||
|
|
@ -65,7 +64,6 @@ module DiasporaFederation
|
|||
@properties = {}
|
||||
end
|
||||
|
||||
##
|
||||
# Generates an XML document from the current instance and returns it as string
|
||||
# @return [String] XML document
|
||||
def to_xml
|
||||
|
|
@ -83,7 +81,6 @@ module DiasporaFederation
|
|||
builder.to_xml
|
||||
end
|
||||
|
||||
##
|
||||
# Parse the XRD document from the given string and create a hash containing
|
||||
# the extracted data.
|
||||
#
|
||||
|
|
|
|||
Loading…
Reference in a new issue