Class: Katello::Util::UrlMatcher::Path

Inherits:
Object
  • Object
show all
Defined in:
app/lib/katello/util/url_matcher.rb

Direct Known Subclasses

Pattern

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path) ⇒ Path

Returns a new instance of Path.



39
40
41
# File 'app/lib/katello/util/url_matcher.rb', line 39

def initialize(path)
  self.parts, self.ext = split_path(path)
end

Instance Attribute Details

#extObject

Returns the value of attribute ext.



37
38
39
# File 'app/lib/katello/util/url_matcher.rb', line 37

def ext
  @ext
end

#partsObject

Returns the value of attribute parts.



37
38
39
# File 'app/lib/katello/util/url_matcher.rb', line 37

def parts
  @parts
end

Instance Method Details

#to_sObject



43
44
45
# File 'app/lib/katello/util/url_matcher.rb', line 43

def to_s
  '/' + self.parts.join('/') + self.ext
end