Linux premium71.web-hosting.com 4.18.0-513.11.1.lve.el8.x86_64 #1 SMP Thu Jan 18 16:21:02 UTC 2024 x86_64
LiteSpeed
Server IP : 198.187.29.8 & Your IP : 18.217.200.151
Domains :
Cant Read [ /etc/named.conf ]
User : cleahvkv
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
opt /
alt /
ruby19 /
lib64 /
ruby /
1.9.1 /
Delete
Unzip
Name
Size
Permission
Date
Action
cgi
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
date
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
digest
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
dl
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
drb
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
fiddle
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
irb
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
json
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
matrix
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
net
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
openssl
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
optparse
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
psych
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
racc
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
rake
[ DIR ]
drwxr-xr-x
2024-03-03 22:50
rbconfig
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
rdoc
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
rexml
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
rinda
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
ripper
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
rss
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
rubygems
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
shell
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
syck
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
test
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
uri
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
webrick
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
x86_64-linux
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
xmlrpc
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
yaml
[ DIR ]
drwxr-xr-x
2024-03-03 22:48
English.rb
5.59
KB
-rw-r--r--
2009-10-02 10:45
abbrev.rb
2.57
KB
-rw-r--r--
2011-05-18 21:19
base64.rb
2.63
KB
-rw-r--r--
2009-10-02 10:45
benchmark.rb
18
KB
-rw-r--r--
2011-06-28 06:09
cgi.rb
9.3
KB
-rw-r--r--
2011-05-16 21:21
cmath.rb
7.22
KB
-rw-r--r--
2011-07-30 14:53
complex.rb
380
B
-rw-r--r--
2009-08-16 15:34
csv.rb
82.66
KB
-rw-r--r--
2011-07-21 21:40
date.rb
946
B
-rw-r--r--
2011-05-21 12:25
debug.rb
23.23
KB
-rw-r--r--
2011-06-28 11:45
delegate.rb
9.74
KB
-rw-r--r--
2011-07-27 19:56
digest.rb
2.24
KB
-rw-r--r--
2011-05-16 20:52
dl.rb
176
B
-rw-r--r--
2010-06-12 15:28
drb.rb
19
B
-rw-r--r--
2009-10-02 10:45
e2mmap.rb
3.8
KB
-rw-r--r--
2011-05-19 00:07
erb.rb
25.72
KB
-rw-r--r--
2012-12-13 05:24
expect.rb
1.33
KB
-rw-r--r--
2011-08-26 23:54
fiddle.rb
928
B
-rw-r--r--
2011-08-16 00:51
fileutils.rb
45.32
KB
-rw-r--r--
2012-02-25 08:11
find.rb
2.03
KB
-rw-r--r--
2011-05-18 21:19
forwardable.rb
7.64
KB
-rw-r--r--
2011-05-22 02:14
getoptlong.rb
15.38
KB
-rw-r--r--
2011-05-19 00:07
gserver.rb
8.83
KB
-rw-r--r--
2013-10-31 14:40
ipaddr.rb
24.92
KB
-rw-r--r--
2013-04-11 02:31
irb.rb
8.34
KB
-rw-r--r--
2011-05-19 00:07
json.rb
1.74
KB
-rw-r--r--
2011-08-30 02:25
kconv.rb
5.74
KB
-rw-r--r--
2010-12-07 11:47
logger.rb
20.85
KB
-rw-r--r--
2011-05-19 00:07
mathn.rb
6.52
KB
-rw-r--r--
2011-08-26 23:54
matrix.rb
47.65
KB
-rw-r--r--
2011-07-09 19:11
mkmf.rb
68.9
KB
-rw-r--r--
2014-02-06 05:20
monitor.rb
6.94
KB
-rw-r--r--
2011-06-17 22:33
mutex_m.rb
1.61
KB
-rw-r--r--
2011-05-19 00:07
observer.rb
5.69
KB
-rw-r--r--
2011-05-16 21:53
open-uri.rb
25.84
KB
-rw-r--r--
2014-02-24 03:43
open3.rb
20.64
KB
-rw-r--r--
2011-05-18 21:19
openssl.rb
547
B
-rw-r--r--
2011-07-25 06:38
optparse.rb
51.13
KB
-rw-r--r--
2014-02-14 04:52
ostruct.rb
6.49
KB
-rw-r--r--
2012-02-24 14:49
pathname.rb
14.21
KB
-rw-r--r--
2011-08-26 23:54
pp.rb
13.31
KB
-rw-r--r--
2010-08-01 14:09
prettyprint.rb
9.63
KB
-rw-r--r--
2011-08-02 15:25
prime.rb
13.98
KB
-rw-r--r--
2011-06-01 00:21
profile.rb
205
B
-rw-r--r--
2009-10-02 10:45
profiler.rb
1.59
KB
-rw-r--r--
2009-10-02 10:45
pstore.rb
15.81
KB
-rw-r--r--
2011-10-10 23:14
psych.rb
9.82
KB
-rw-r--r--
2012-08-07 20:50
rake.rb
2.02
KB
-rw-r--r--
2011-06-29 03:09
rational.rb
308
B
-rw-r--r--
2009-09-24 00:42
rdoc.rb
4.29
KB
-rw-r--r--
2013-02-06 08:00
resolv-replace.rb
1.74
KB
-rw-r--r--
2010-10-29 22:02
resolv.rb
59.91
KB
-rw-r--r--
2014-02-14 06:56
ripper.rb
91
B
-rw-r--r--
2009-10-02 10:45
rss.rb
2.84
KB
-rw-r--r--
2011-05-11 10:22
rubygems.rb
34.13
KB
-rw-r--r--
2013-12-22 04:38
scanf.rb
23.53
KB
-rw-r--r--
2011-05-20 12:22
securerandom.rb
8.46
KB
-rw-r--r--
2012-05-07 11:25
set.rb
29.91
KB
-rw-r--r--
2012-02-10 08:28
shell.rb
5.9
KB
-rw-r--r--
2011-05-19 00:07
shellwords.rb
3.88
KB
-rw-r--r--
2012-02-12 07:51
singleton.rb
4.02
KB
-rw-r--r--
2011-05-18 14:09
socket.rb
23.22
KB
-rw-r--r--
2014-01-30 12:04
syck.rb
13.91
KB
-rw-r--r--
2010-07-19 04:54
sync.rb
6.87
KB
-rw-r--r--
2011-06-29 03:09
tempfile.rb
10.42
KB
-rw-r--r--
2013-10-31 14:44
thread.rb
6.59
KB
-rw-r--r--
2014-02-14 03:48
thwait.rb
3.38
KB
-rw-r--r--
2011-06-29 03:09
time.rb
17.03
KB
-rw-r--r--
2013-10-31 14:06
timeout.rb
3.26
KB
-rw-r--r--
2013-04-02 04:09
tmpdir.rb
3.72
KB
-rw-r--r--
2011-05-18 21:19
tracer.rb
6.63
KB
-rw-r--r--
2011-06-29 13:19
tsort.rb
6.79
KB
-rw-r--r--
2009-03-06 04:23
ubygems.rb
268
B
-rw-r--r--
2009-10-02 10:45
un.rb
8.32
KB
-rw-r--r--
2011-05-19 00:07
uri.rb
3.07
KB
-rw-r--r--
2011-05-13 20:03
weakref.rb
2.29
KB
-rw-r--r--
2011-08-26 23:54
webrick.rb
6.8
KB
-rw-r--r--
2011-05-10 23:37
yaml.rb
2.58
KB
-rw-r--r--
2013-05-29 12:00
Save
Rename
# This class implements a pretty printing algorithm. It finds line breaks and # nice indentations for grouped structure. # # By default, the class assumes that primitive elements are strings and each # byte in the strings have single column in width. But it can be used for # other situations by giving suitable arguments for some methods: # * newline object and space generation block for PrettyPrint.new # * optional width argument for PrettyPrint#text # * PrettyPrint#breakable # # There are several candidate uses: # * text formatting using proportional fonts # * multibyte characters which has columns different to number of bytes # * non-string formatting # # == Bugs # * Box based formatting? # * Other (better) model/algorithm? # # == References # Christian Lindig, Strictly Pretty, March 2000, # http://www.st.cs.uni-sb.de/~lindig/papers/#pretty # # Philip Wadler, A prettier printer, March 1998, # http://homepages.inf.ed.ac.uk/wadler/topics/language-design.html#prettier # # == Author # Tanaka Akira <akr@m17n.org> # class PrettyPrint # This is a convenience method which is same as follows: # # begin # q = PrettyPrint.new(output, maxwidth, newline, &genspace) # ... # q.flush # output # end # def PrettyPrint.format(output='', maxwidth=79, newline="\n", genspace=lambda {|n| ' ' * n}) q = PrettyPrint.new(output, maxwidth, newline, &genspace) yield q q.flush output end # This is similar to PrettyPrint::format but the result has no breaks. # # +maxwidth+, +newline+ and +genspace+ are ignored. # # The invocation of +breakable+ in the block doesn't break a line and is # treated as just an invocation of +text+. # def PrettyPrint.singleline_format(output='', maxwidth=nil, newline=nil, genspace=nil) q = SingleLine.new(output) yield q output end # Creates a buffer for pretty printing. # # +output+ is an output target. If it is not specified, '' is assumed. It # should have a << method which accepts the first argument +obj+ of # PrettyPrint#text, the first argument +sep+ of PrettyPrint#breakable, the # first argument +newline+ of PrettyPrint.new, and the result of a given # block for PrettyPrint.new. # # +maxwidth+ specifies maximum line length. If it is not specified, 79 is # assumed. However actual outputs may overflow +maxwidth+ if long # non-breakable texts are provided. # # +newline+ is used for line breaks. "\n" is used if it is not specified. # # The block is used to generate spaces. {|width| ' ' * width} is used if it # is not given. # def initialize(output='', maxwidth=79, newline="\n", &genspace) @output = output @maxwidth = maxwidth @newline = newline @genspace = genspace || lambda {|n| ' ' * n} @output_width = 0 @buffer_width = 0 @buffer = [] root_group = Group.new(0) @group_stack = [root_group] @group_queue = GroupQueue.new(root_group) @indent = 0 end attr_reader :output, :maxwidth, :newline, :genspace attr_reader :indent, :group_queue # Returns the group most recently added to the stack. def current_group @group_stack.last end # first? is a predicate to test the call is a first call to first? with # current group. # # It is useful to format comma separated values as: # # q.group(1, '[', ']') { # xxx.each {|yyy| # unless q.first? # q.text ',' # q.breakable # end # ... pretty printing yyy ... # } # } # # first? is obsoleted in 1.8.2. # def first? warn "PrettyPrint#first? is obsoleted at 1.8.2." current_group.first? end # Breaks the buffer into lines that are shorter than #maxwidth def break_outmost_groups while @maxwidth < @output_width + @buffer_width return unless group = @group_queue.deq until group.breakables.empty? data = @buffer.shift @output_width = data.output(@output, @output_width) @buffer_width -= data.width end while !@buffer.empty? && Text === @buffer.first text = @buffer.shift @output_width = text.output(@output, @output_width) @buffer_width -= text.width end end end # This adds +obj+ as a text of +width+ columns in width. # # If +width+ is not specified, obj.length is used. # def text(obj, width=obj.length) if @buffer.empty? @output << obj @output_width += width else text = @buffer.last unless Text === text text = Text.new @buffer << text end text.add(obj, width) @buffer_width += width break_outmost_groups end end # This is similar to #breakable except # the decision to break or not is determined individually. # # Two #fill_breakable under a group may cause 4 results: # (break,break), (break,non-break), (non-break,break), (non-break,non-break). # This is different to #breakable because two #breakable under a group # may cause 2 results: # (break,break), (non-break,non-break). # # The text sep+ is inserted if a line is not broken at this point. # # If +sep+ is not specified, " " is used. # # If +width+ is not specified, +sep.length+ is used. You will have to # specify this when +sep+ is a multibyte character, for example. # def fill_breakable(sep=' ', width=sep.length) group { breakable sep, width } end # This says "you can break a line here if necessary", and a +width+\-column # text +sep+ is inserted if a line is not broken at the point. # # If +sep+ is not specified, " " is used. # # If +width+ is not specified, +sep.length+ is used. You will have to # specify this when +sep+ is a multibyte character, for example. # def breakable(sep=' ', width=sep.length) group = @group_stack.last if group.break? flush @output << @newline @output << @genspace.call(@indent) @output_width = @indent @buffer_width = 0 else @buffer << Breakable.new(sep, width, self) @buffer_width += width break_outmost_groups end end # Groups line break hints added in the block. The line break hints are all # to be used or not. # # If +indent+ is specified, the method call is regarded as nested by # nest(indent) { ... }. # # If +open_obj+ is specified, <tt>text open_obj, open_width</tt> is called # before grouping. If +close_obj+ is specified, <tt>text close_obj, # close_width</tt> is called after grouping. # def group(indent=0, open_obj='', close_obj='', open_width=open_obj.length, close_width=close_obj.length) text open_obj, open_width group_sub { nest(indent) { yield } } text close_obj, close_width end def group_sub group = Group.new(@group_stack.last.depth + 1) @group_stack.push group @group_queue.enq group begin yield ensure @group_stack.pop if group.breakables.empty? @group_queue.delete group end end end # Increases left margin after newline with +indent+ for line breaks added in # the block. # def nest(indent) @indent += indent begin yield ensure @indent -= indent end end # outputs buffered data. # def flush @buffer.each {|data| @output_width = data.output(@output, @output_width) } @buffer.clear @buffer_width = 0 end class Text def initialize @objs = [] @width = 0 end attr_reader :width def output(out, output_width) @objs.each {|obj| out << obj} output_width + @width end def add(obj, width) @objs << obj @width += width end end class Breakable def initialize(sep, width, q) @obj = sep @width = width @pp = q @indent = q.indent @group = q.current_group @group.breakables.push self end attr_reader :obj, :width, :indent def output(out, output_width) @group.breakables.shift if @group.break? out << @pp.newline out << @pp.genspace.call(@indent) @indent else @pp.group_queue.delete @group if @group.breakables.empty? out << @obj output_width + @width end end end class Group def initialize(depth) @depth = depth @breakables = [] @break = false end attr_reader :depth, :breakables def break @break = true end def break? @break end def first? if defined? @first false else @first = false true end end end class GroupQueue def initialize(*groups) @queue = [] groups.each {|g| enq g} end def enq(group) depth = group.depth @queue << [] until depth < @queue.length @queue[depth] << group end def deq @queue.each {|gs| (gs.length-1).downto(0) {|i| unless gs[i].breakables.empty? group = gs.slice!(i, 1).first group.break return group end } gs.each {|group| group.break} gs.clear } return nil end def delete(group) @queue[group.depth].delete(group) end end class SingleLine def initialize(output, maxwidth=nil, newline=nil) @output = output @first = [true] end def text(obj, width=nil) @output << obj end def breakable(sep=' ', width=nil) @output << sep end def nest(indent) yield end def group(indent=nil, open_obj='', close_obj='', open_width=nil, close_width=nil) @first.push true @output << open_obj yield @output << close_obj @first.pop end def flush end def first? result = @first[-1] @first[-1] = false result end end end