Class: Sass::Engine::Line
- Inherits:
- Struct
- Object
- Struct
- Sass::Engine::Line
- Defined in:
- /Users/ceppstei/Projects/sass-lang/.sass/lib/sass/engine.rb
Overview
A line of Sass code.
text
:String
- The text in the line, without any whitespace at the beginning or end.
tabs
:Fixnum
- The level of indentation of the line.
index
:Fixnum
- The line number in the original document.
offset
:Fixnum
- The number of bytes in on the line that the text begins. This ends up being the number of bytes of leading whitespace.
filename
:String
- The name of the file in which this line appeared.
children
:Array<Line>
- The lines nested below this one.
comment_tab_str
:String?
- The prefix indentation for this comment, if it is a comment.
Instance Attribute Summary (collapse)
- - (Object) children
Returns the value of attribute children.
- - (Object) comment_tab_str
Returns the value of attribute comment_tab_str.
- - (Object) filename
Returns the value of attribute filename.
- - (Object) index
Returns the value of attribute index.
- - (Object) offset
Returns the value of attribute offset.
- - (Object) tabs
Returns the value of attribute tabs.
- - (Object) text
Returns the value of attribute text.
Instance Method Summary (collapse)
Instance Attribute Details
- (Object) children
Returns the value of attribute children
115 116 117 | # File '/Users/ceppstei/Projects/sass-lang/.sass/lib/sass/engine.rb', line 115
def children
@children
end |
- (Object) comment_tab_str
Returns the value of attribute comment_tab_str
115 116 117 | # File '/Users/ceppstei/Projects/sass-lang/.sass/lib/sass/engine.rb', line 115
def comment_tab_str
@comment_tab_str
end |
- (Object) filename
Returns the value of attribute filename
115 116 117 | # File '/Users/ceppstei/Projects/sass-lang/.sass/lib/sass/engine.rb', line 115
def filename
@filename
end |
- (Object) index
Returns the value of attribute index
115 116 117 | # File '/Users/ceppstei/Projects/sass-lang/.sass/lib/sass/engine.rb', line 115
def index
@index
end |
- (Object) offset
Returns the value of attribute offset
115 116 117 | # File '/Users/ceppstei/Projects/sass-lang/.sass/lib/sass/engine.rb', line 115
def offset
@offset
end |
- (Object) tabs
Returns the value of attribute tabs
115 116 117 | # File '/Users/ceppstei/Projects/sass-lang/.sass/lib/sass/engine.rb', line 115
def tabs
@tabs
end |
- (Object) text
Returns the value of attribute text
115 116 117 | # File '/Users/ceppstei/Projects/sass-lang/.sass/lib/sass/engine.rb', line 115
def text
@text
end |
Instance Method Details
- (Boolean) comment?
116 117 118 | # File '/Users/ceppstei/Projects/sass-lang/.sass/lib/sass/engine.rb', line 116
def comment?
text[0] == COMMENT_CHAR && (text[1] == SASS_COMMENT_CHAR || text[1] == CSS_COMMENT_CHAR)
end |