• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeedu API Reference
  • KDE Home
  • Contact Us
 

Analitza

  • sources
  • kde-4.14
  • kdeedu
  • analitza
  • analitza
variable.h
Go to the documentation of this file.
1 /*************************************************************************************
2  * Copyright (C) 2007 by Aleix Pol <aleixpol@kde.org> *
3  * *
4  * This program is free software; you can redistribute it and/or *
5  * modify it under the terms of the GNU General Public License *
6  * as published by the Free Software Foundation; either version 2 *
7  * of the License, or (at your option) any later version. *
8  * *
9  * This program is distributed in the hope that it will be useful, *
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
12  * GNU General Public License for more details. *
13  * *
14  * You should have received a copy of the GNU General Public License *
15  * along with this program; if not, write to the Free Software *
16  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA *
17  *************************************************************************************/
18 
19 #ifndef VARIABLE_H
20 #define VARIABLE_H
21 
22 #include "object.h"
23 namespace Analitza
24 {
25 
34 class ANALITZA_EXPORT Ci : public Object
35 {
36  public:
38  explicit Ci(const QString& b);
39 
40  ~Ci();
41 
43  QString name() const { return m_name; }
44 
46  bool operator==(const Ci& var) const { return var.m_name==m_name; }
47 
49  void setFunction(bool f) { m_function=f; }
50 
52  bool isFunction() const { return m_function; }
53 
55  QString toMathML() const;
56 
58  QString toHtml() const;
59 
60  virtual QVariant accept(AbstractExpressionVisitor*) const;
61  virtual bool matches(const Object* pattern, QMap<QString, const Object*>* found) const;
62  Ci* copy() const;
63 
64  void setBVarDepth(int depth) { m_depth = depth; }
65  int depth() const { return m_depth; }
66 
67  void setName(const QString& newName) { m_name = newName; }
68 
69  private:
70  QString m_name;
71  bool m_function;
72  int m_depth;
73 };
74 
75 }
76 #endif
Analitza::AbstractExpressionVisitor
Definition: abstractexpressionvisitor.h:49
Analitza::Ci::depth
int depth() const
Definition: variable.h:65
Analitza::Ci::isFunction
bool isFunction() const
Returns whether it is a variable that has to be a function.
Definition: variable.h:52
QMap
Analitza::Ci::name
QString name() const
Returns the variable name.
Definition: variable.h:43
Analitza::Ci
A variable object, name refers to MathML standard.
Definition: variable.h:34
Analitza::Ci::operator==
bool operator==(const Ci &var) const
Returns whether var name is equal to this variable one.
Definition: variable.h:46
QString
Analitza::Ci::setBVarDepth
void setBVarDepth(int depth)
Definition: variable.h:64
Analitza::Ci::setFunction
void setFunction(bool f)
Sets whether it is a function.
Definition: variable.h:49
Analitza::Object
Definition: object.h:38
object.h
ANALITZA_EXPORT
#define ANALITZA_EXPORT
Definition: analitzaexport.h:31
Analitza::Ci::setName
void setName(const QString &newName)
Definition: variable.h:67
QVariant
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:11:37 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

Analitza

Skip menu "Analitza"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Modules
  • Related Pages

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal