Class: Instadoc::Java::JavaCode

Inherits:
Object
  • Object
show all
Defined in:
lib/instadoc/java/java_code.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(config) ⇒ JavaCode

Returns a new instance of JavaCode.



9
10
11
12
13
# File 'lib/instadoc/java/java_code.rb', line 9

def initialize(config)
  @config = config
  @files = Array.new
  @java_file_seeker = PathnameSeeker.new(@config)
end

Instance Attribute Details

#filesObject (readonly)

Returns the value of attribute files.



15
16
17
# File 'lib/instadoc/java/java_code.rb', line 15

def files
  @files
end

Instance Method Details

#search(base_pathname) ⇒ Object



17
18
19
20
# File 'lib/instadoc/java/java_code.rb', line 17

def search(base_pathname)
  path_names = @java_file_seeker.search_in(base_pathname)
  @files.concat(JavaFile.create_files(@config, path_names))
end

#to_sObject



22
23
24
# File 'lib/instadoc/java/java_code.rb', line 22

def to_s
  "Instadoc::JavaCode"
end