1 #ifndef MUP_SCRIPT_TOKENS_H 2 #define MUP_SCRIPT_TOKENS_H 3 4 /** \file 5 \brief Definition of basic types used by muParserX 6 7 <pre> 8 __________ ____ ___ 9 _____ __ _\______ \_____ _______ ______ __________\ \/ / 10 / \| | \ ___/\__ \\_ __ \/ ___// __ \_ __ \ / 11 | Y Y \ | / | / __ \| | \/\___ \\ ___/| | \/ \ 12 |__|_| /____/|____| (____ /__| /____ >\___ >__| /___/\ \ 13 \/ \/ \/ \/ \_/ 14 Copyright (C) 2016, Ingo Berg 15 All rights reserved. 16 17 Redistribution and use in source and binary forms, with or without 18 modification, are permitted provided that the following conditions are met: 19 20 * Redistributions of source code must retain the above copyright notice, 21 this list of conditions and the following disclaimer. 22 * Redistributions in binary form must reproduce the above copyright notice, 23 this list of conditions and the following disclaimer in the documentation 24 and/or other materials provided with the distribution. 25 26 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 27 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 28 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 29 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 30 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 31 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 32 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 33 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 34 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 35 POSSIBILITY OF SUCH DAMAGE. 36 </pre> 37 */ 38 39 #include "mpIToken.h" 40 41 42 MUP_NAMESPACE_START 43 44 //--------------------------------------------------------------------------- 45 /** \brief A class for encapsulation a newline token. */ 46 class TokenNewline : public IToken 47 { 48 public: 49 50 TokenNewline(); 51 52 //--------------------------------------------- 53 // IToken interface 54 //--------------------------------------------- 55 56 virtual IToken* Clone() const; 57 virtual string_type AsciiDump() const; 58 59 int GetStackOffset() const; 60 void SetStackOffset(int nOffset); 61 62 private: 63 int m_nOffset; 64 }; 65 66 MUP_NAMESPACE_END 67 68 #endif 69