Skip to content

Commit

Permalink
Mark private API
Browse files Browse the repository at this point in the history
  • Loading branch information
denisdefreyne committed May 6, 2015
1 parent a1f7997 commit f3a1642
Show file tree
Hide file tree
Showing 80 changed files with 123 additions and 2 deletions.
2 changes: 2 additions & 0 deletions lib/nanoc/base/checksummer.rb
Expand Up @@ -5,6 +5,8 @@ module Nanoc
#
# A checksum is a string, such as “mL+TaqNsEeiPkWloPgCtAofT1yg=”, that is used
# to determine whether a piece of data has changed.
#
# @api private
class Checksummer
class << self
# @param obj The object to create a checksum for
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/base/compilation/compiler.rb
Expand Up @@ -37,6 +37,8 @@ module Nanoc
#
# * `processing_ended` — indicates that the compiler has finished processing
# the specified object.
#
# @api private
class Compiler
extend Nanoc::Memoization

Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/base/compilation/outdatedness_reasons.rb
Expand Up @@ -2,6 +2,8 @@

module Nanoc
# Module that contains all outdatedness reasons.
#
# @api private
module OutdatednessReasons
# A generic outdatedness reason. An outdatedness reason is basically a
# descriptive message that explains why a given object is outdated.
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/base/compilation/rule.rb
Expand Up @@ -2,6 +2,8 @@

module Nanoc
# Contains the processing information for a item.
#
# @api private
class Rule
# @return [Regexp] The regex that determines which items this rule can be
# applied to. This rule can be applied to items with a identifier
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/base/directed_graph.rb
Expand Up @@ -28,6 +28,8 @@ module Nanoc
# # => %w( c )
# graph.predecessors_of('d').sort
# # => %w( b c )
#
# @api private
class DirectedGraph
# @group Creating a graph

Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/base/errors.rb
Expand Up @@ -2,6 +2,8 @@

module Nanoc
# Module that contains all nanoc-specific errors.
#
# @api private
module Errors
# Generic error. Superclass for all nanoc-specific errors.
class Generic < ::StandardError
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/base/memoization.rb
Expand Up @@ -3,6 +3,8 @@
module Nanoc
# Adds support for memoizing functions.
#
# @api private
#
# @since 3.2.0
module Memoization
# Memoizes the method with the given name. The modified method will cache
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/base/notification_center.rb
Expand Up @@ -8,6 +8,8 @@ module Nanoc
# It is a slightly different implementation of the Observer pattern; the
# table of subscribers is not stored in the observable object itself, but in
# the notification center.
#
# @api private
class NotificationCenter
class << self
# Adds the given block to the list of blocks that should be called when
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/base/plugin_registry.rb
Expand Up @@ -4,6 +4,8 @@ module Nanoc
# The class responsible for keeping track of all loaded plugins, such as
# filters ({Nanoc::Filter}), data sources ({Nanoc::DataSource}) and VCSes
# ({Nanoc::Extra::VCS}).
#
# @api private
class PluginRegistry
extend Nanoc::Memoization

Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/base/source_data/code_snippet.rb
Expand Up @@ -2,6 +2,8 @@

module Nanoc
# Nanoc::CodeSnippet represent a piece of custom code of a nanoc site.
#
# @api private
class CodeSnippet
# A string containing the actual code in this code snippet.
#
Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/base/temp_filename_factory.rb
Expand Up @@ -3,6 +3,7 @@
require 'tmpdir'

module Nanoc
# @api private
class TempFilenameFactory
# @return [String] The root directory for all temporary filenames
attr_reader :root_dir
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/cli/ansi_string_colorizer.rb
Expand Up @@ -3,6 +3,8 @@
module Nanoc::CLI
# A simple ANSI colorizer for strings. When given a string and a list of
# attributes, it returns a colorized string.
#
# @api private
module ANSIStringColorizer
# TODO: complete mapping
MAPPING = {
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/cli/cleaning_stream.rb
Expand Up @@ -3,6 +3,8 @@
module Nanoc::CLI
# An output stream that passes output through stream cleaners. This can be
# used to strip ANSI color sequences, for instance.
#
# @api private
class CleaningStream
# @param [IO, StringIO] stream The stream to wrap
def initialize(stream)
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/cli/command_runner.rb
Expand Up @@ -3,6 +3,8 @@
module Nanoc::CLI
# A command runner subclass for nanoc commands that adds nanoc-specific
# convenience methods and error handling.
#
# @api private
class CommandRunner < ::Cri::CommandRunner
# @see http://rubydoc.info/gems/cri/Cri/CommandRunner#call-instance_method
#
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/cli/logger.rb
Expand Up @@ -5,6 +5,8 @@
module Nanoc::CLI
# Nanoc::CLI::Logger is a singleton class responsible for generating
# feedback in the terminal.
#
# @api private
class Logger
# Maps actions (`:create`, `:update`, `:identical`, `:skip` and `:delete`)
# onto their ANSI color codes.
Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/cli/stream_cleaners.rb
@@ -1,6 +1,7 @@
# encoding: utf-8

module Nanoc::CLI
# @api private
module StreamCleaners
autoload 'Abstract', 'nanoc/cli/stream_cleaners/abstract'
autoload 'ANSIColors', 'nanoc/cli/stream_cleaners/ansi_colors'
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/cli/stream_cleaners/abstract.rb
Expand Up @@ -6,6 +6,8 @@ module Nanoc::CLI::StreamCleaners
# can have state, so they can act as a FSM.
#
# @abstract Subclasses must implement {#clean}
#
# @api private
class Abstract
# Returns a cleaned version of the given string.
#
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/cli/stream_cleaners/ansi_colors.rb
Expand Up @@ -2,6 +2,8 @@

module Nanoc::CLI::StreamCleaners
# Removes ANSI color escape sequences.
#
# @api private
class ANSIColors < Abstract
# @see Nanoc::CLI::StreamCleaners::Abstract#clean
def clean(s)
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/cli/stream_cleaners/utf8.rb
Expand Up @@ -2,6 +2,8 @@

module Nanoc::CLI::StreamCleaners
# Simplifies output by replacing UTF-8 characters with their ASCII decompositions.
#
# @api private
class UTF8 < Abstract
# @see Nanoc::CLI::StreamCleaners::Abstract#clean
def clean(s)
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/data_sources/filesystem.rb
Expand Up @@ -2,6 +2,8 @@

module Nanoc::DataSources
# Provides functionality common across all filesystem data sources.
#
# @api private
module Filesystem
# The VCS that will be called when adding, deleting and moving files. If
# no VCS has been set, or if the VCS has been set to `nil`, a dummy VCS
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/data_sources/filesystem_unified.rb
Expand Up @@ -66,6 +66,8 @@ module Nanoc::DataSources
# files. In the data source configuration, set `encoding` to an encoding
# understood by Ruby’s `Encoding`. If no encoding is set in the configuration,
# one will be inferred from the environment.
#
# @api private
class FilesystemUnified < Nanoc::DataSource
include Nanoc::DataSources::Filesystem

Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/data_sources/filesystem_verbose.rb
Expand Up @@ -38,6 +38,8 @@ module Nanoc::DataSources
# files. In the data source configuration, set `encoding` to an encoding
# understood by Ruby’s `Encoding`. If no encoding is set in the configuration,
# one will be inferred from the environment.
#
# @api private
class FilesystemVerbose < Nanoc::DataSource
include Nanoc::DataSources::Filesystem

Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/data_sources/static.rb
Expand Up @@ -24,6 +24,8 @@ module Nanoc::DataSources
# data sources will have the :is_hidden attribute set by default, which will
# exclude them from the Blogging helper's atom feed generator, among other
# things.
#
# @api private
class Static < Nanoc::DataSource
identifier :static

Expand Down
2 changes: 0 additions & 2 deletions lib/nanoc/extra.rb
@@ -1,9 +1,7 @@
# encoding: utf-8

module Nanoc::Extra
autoload 'AutoCompiler', 'nanoc/extra/auto_compiler'
autoload 'Checking', 'nanoc/extra/checking'
autoload 'CHiCk', 'nanoc/extra/chick'
autoload 'FilesystemTools', 'nanoc/extra/filesystem_tools'
autoload 'LinkCollector', 'nanoc/extra/link_collector.rb'
autoload 'Pruner', 'nanoc/extra/pruner'
Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/checking.rb
@@ -1,6 +1,7 @@
# encoding: utf-8

module Nanoc::Extra
# @api private
module Checking
autoload 'Check', 'nanoc/extra/checking/check'
autoload 'DSL', 'nanoc/extra/checking/dsl'
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/extra/checking/check.rb
@@ -1,12 +1,14 @@
# encoding: utf-8

module Nanoc::Extra::Checking
# @api private
class OutputDirNotFoundError < Nanoc::Errors::Generic
def initialize(directory_path)
super("Unable to run check against output directory at “#{directory_path}”: directory does not exist.")
end
end

# @api private
class Check
extend Nanoc::PluginRegistry::PluginMethods

Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/checking/checks.rb
@@ -1,5 +1,6 @@
# encoding: utf-8

# @api private
module Nanoc::Extra::Checking::Checks
autoload 'CSS', 'nanoc/extra/checking/checks/css'
autoload 'ExternalLinks', 'nanoc/extra/checking/checks/external_links'
Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/checking/checks/css.rb
@@ -1,6 +1,7 @@
# encoding: utf-8

module ::Nanoc::Extra::Checking::Checks
# @api private
class CSS < ::Nanoc::Extra::Checking::Check
identifier :css

Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/extra/checking/checks/external_links.rb
Expand Up @@ -8,6 +8,8 @@

module ::Nanoc::Extra::Checking::Checks
# A validator that verifies that all external links point to a location that exists.
#
# @api private
class ExternalLinks < ::Nanoc::Extra::Checking::Check
identifiers :external_links, :elinks

Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/checking/checks/html.rb
@@ -1,6 +1,7 @@
# encoding: utf-8

module ::Nanoc::Extra::Checking::Checks
# @api private
class HTML < ::Nanoc::Extra::Checking::Check
identifier :html

Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/extra/checking/checks/internal_links.rb
Expand Up @@ -4,6 +4,8 @@

module Nanoc::Extra::Checking::Checks
# A check that verifies that all internal links point to a location that exists.
#
# @api private
class InternalLinks < ::Nanoc::Extra::Checking::Check
# Starts the validator. The results will be printed to stdout.
#
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/extra/checking/checks/mixed_content.rb
Expand Up @@ -3,6 +3,8 @@
module Nanoc::Extra::Checking::Checks
# A check that verifies HTML files do not reference external resources with
# URLs that would trigger "mixed content" warnings.
#
# @api private
class MixedContent < ::Nanoc::Extra::Checking::Check
PROTOCOL_PATTERN = /^(\w+):\/\//

Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/checking/checks/stale.rb
@@ -1,6 +1,7 @@
# encoding: utf-8

module Nanoc::Extra::Checking::Checks
# @api private
class Stale < ::Nanoc::Extra::Checking::Check
def run
require 'set'
Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/checking/dsl.rb
@@ -1,6 +1,7 @@
# encoding: utf-8

module Nanoc::Extra::Checking
# @api private
class DSL
attr_reader :deploy_checks

Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/checking/issue.rb
@@ -1,6 +1,7 @@
# encoding: utf-8

module Nanoc::Extra::Checking
# @api private
class Issue
attr_reader :description
attr_reader :subject
Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/core_ext/pathname.rb
@@ -1,6 +1,7 @@
# encoding: utf-8

module Nanoc::Extra
# @api private
module PathnameExtensions
def components
components = []
Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/core_ext/time.rb
@@ -1,5 +1,6 @@
# encoding: utf-8

# @api private
module Nanoc::Extra::TimeExtensions
# @return [String] The time in an ISO-8601 date format.
def to_iso8601_date
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/extra/deployer.rb
Expand Up @@ -5,6 +5,8 @@ module Nanoc::Extra
# to a specific (remote) location.
#
# @abstract Subclass and override {#run} to implement a custom filter.
#
# @api private
class Deployer
extend Nanoc::PluginRegistry::PluginMethods

Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/deployers.rb
@@ -1,6 +1,7 @@
# encoding: utf-8

module Nanoc::Extra
# @api private
module Deployers
autoload 'Fog', 'nanoc/extra/deployers/fog'
autoload 'Rsync', 'nanoc/extra/deployers/rsync'
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/extra/deployers/fog.rb
Expand Up @@ -20,6 +20,8 @@ module Nanoc::Extra::Deployers
# provider: local
# local_root: ~/myCloud
# bucket: nanoc-site-staging
#
# @api private
class Fog < ::Nanoc::Extra::Deployer
# @see Nanoc::Extra::Deployer#run
def run
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/extra/deployers/rsync.rb
Expand Up @@ -18,6 +18,8 @@ module Nanoc::Extra::Deployers
# kind: rsync
# dst: "ectype:sites/stoneship-staging/public"
# options: [ "-glpPrtvz" ]
#
# @api private
class Rsync < ::Nanoc::Extra::Deployer
# Default rsync options
DEFAULT_OPTIONS = [
Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/jruby_nokogiri_warner.rb
Expand Up @@ -3,6 +3,7 @@
require 'singleton'

module Nanoc::Extra
# @api private
class JRubyNokogiriWarner
include Singleton

Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/link_collector.rb
Expand Up @@ -3,6 +3,7 @@
require 'set'

module ::Nanoc::Extra
# @api private
class LinkCollector
URI_ATTRS = {
'a' => :href,
Expand Down
1 change: 1 addition & 0 deletions lib/nanoc/extra/piper.rb
Expand Up @@ -3,6 +3,7 @@
require 'open3'

module Nanoc::Extra
# @api private
class Piper
class Error < ::Nanoc::Errors::Generic
def initialize(command, exit_code)
Expand Down
2 changes: 2 additions & 0 deletions lib/nanoc/extra/pruner.rb
Expand Up @@ -3,6 +3,8 @@
module Nanoc::Extra
# Responsible for finding and deleting files in the site’s output directory
# that are not managed by nanoc.
#
# @api private
class Pruner
# @return [Nanoc::Site] The site this pruner belongs to
attr_reader :site
Expand Down

0 comments on commit f3a1642

Please sign in to comment.