Current Version: 1.0.33
Project Name: csspp
position.h
Go to the documentation of this file.
1// Copyright (c) 2015-2025 Made to Order Software Corp. All Rights Reserved
2//
3// This program is free software; you can redistribute it and/or modify
4// it under the terms of the GNU General Public License as published by
5// the Free Software Foundation; either version 2 of the License, or
6// (at your option) any later version.
7//
8// This program is distributed in the hope that it will be useful,
9// but WITHOUT ANY WARRANTY; without even the implied warranty of
10// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11// GNU General Public License for more details.
12//
13// You should have received a copy of the GNU General Public License along
14// with this program; if not, write to the Free Software Foundation, Inc.,
15// 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
16#pragma once
17
18// self
19//
20#include "csspp/csspp.h"
21
22
23// C++
24//
25#include <memory>
26
27
28namespace csspp
29{
30
31typedef int line_t;
32
34{
35public:
36 typedef std::shared_ptr<position> pointer_t;
37
38 position(std::string const & filename, line_t page = 1, line_t line = 1);
39
40 void next_line();
41 void next_page();
42
43 std::string const & get_filename() const;
44 line_t get_page() const;
45 line_t get_line() const;
46 line_t get_total_line() const;
47
48private:
49 std::string f_filename;
53};
54
55} // namespace csspp
56// vim: ts=4 sw=4 et
line_t get_page() const
Definition position.cpp:47
line_t f_page
Definition position.h:50
line_t get_total_line() const
Definition position.cpp:57
line_t f_line
Definition position.h:51
std::string const & get_filename() const
Definition position.cpp:42
std::shared_ptr< position > pointer_t
Definition position.h:36
line_t get_line() const
Definition position.cpp:52
line_t f_total_line
Definition position.h:52
std::string f_filename
Definition position.h:49
The namespace of all the classes in the CSS Preprocessor.
Definition csspp.h:48
int line_t
Definition csspp.h:57

Documentation of CSS Preprocessor.

This document is part of the Snap! Websites Project.

Copyright by Made to Order Software Corp.