SimpleLink.cpp
Go to the documentation of this file.
1 /* Copyright (C) 2008 National Institute For Space Research (INPE) - Brazil.
2 
3  This file is part of the TerraLib - a Framework for building GIS enabled applications.
4 
5  TerraLib is free software: you can redistribute it and/or modify
6  it under the terms of the GNU Lesser General Public License as published by
7  the Free Software Foundation, either version 3 of the License,
8  or (at your option) any later version.
9 
10  TerraLib is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  GNU Lesser General Public License for more details.
14 
15  You should have received a copy of the GNU Lesser General Public License
16  along with TerraLib. See COPYING. If not, write to
17  TerraLib Team at <terralib-team@terralib.org>.
18  */
19 
20 /*!
21  \file SimpleLink.cpp
22 
23  \brief Simple link.
24  */
25 
26 // TerraLib
27 #include "Globals.h"
28 #include "SimpleLink.h"
29 
31  : m_show(SHOW_NONE),
32  m_actuate(ACTUATE_NONE)
33 {
34 }
35 
37 
38 const std::string& te::xl::SimpleLink::getType()
39 {
40  return Globals::sm_xlinkType;
41 }
42 
43 void te::xl::SimpleLink::setHref(const std::string& href)
44 {
45  m_href = href;
46 }
47 
48 const std::string& te::xl::SimpleLink::getHref() const
49 {
50  return m_href;
51 }
52 
53 void te::xl::SimpleLink::setRole(const std::string& role)
54 {
55  m_role = role;
56 }
57 
58 const std::string& te::xl::SimpleLink::getRole() const
59 {
60  return m_role;
61 }
62 
63 void te::xl::SimpleLink::setArcRole(const std::string& arcrole)
64 {
65  m_arcrole = arcrole;
66 }
67 
68 const std::string& te::xl::SimpleLink::getArcRole() const
69 {
70  return m_arcrole;
71 }
72 
73 void te::xl::SimpleLink::setTitle(const std::string& title)
74 {
75  m_title = title;
76 }
77 
78 const std::string& te::xl::SimpleLink::getTitle() const
79 {
80  return m_title;
81 }
82 
84 {
85  m_show = show;
86 }
87 
89 {
90  return m_show;
91 }
92 
94 {
95  m_actuate = actuate;
96 }
97 
99 {
100  return m_actuate;
101 }
102 
104 {
105  SimpleLink* sl = new SimpleLink;
106 
107  sl->m_href = m_href;
108  sl->m_role = m_role;
109  sl->m_arcrole = m_arcrole;
110  sl->m_title = m_title;
111  sl->m_show = m_show;
112  sl->m_actuate = m_actuate;
113 
114  return sl;
115 }
ShowType
The show type attribute is used to communicate the desired presentation of the ending resource on tra...
Definition: Enumerators.h:42
ActuateType
The actuate type attribute is used to communicate the desired timing of traversal from the starting r...
Definition: Enumerators.h:62
static const std::string sm_xlinkType
Fixed value for SimpleLink: "xlink:simple".