Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Cameo
cameo
Commits
7a7d5a79
Commit
7a7d5a79
authored
Oct 21, 2020
by
legoc
Browse files
(split) Renamed Port application names
parent
3bec52f5
Changes
5
Show whitespace changes
Inline
Side-by-side
include/Application.h
View file @
7a7d5a79
...
...
@@ -587,16 +587,16 @@ class Port {
friend
std
::
ostream
&
operator
<<
(
std
::
ostream
&
,
const
Port
&
);
public:
Port
(
int
port
,
const
std
::
string
&
status
,
const
std
::
string
&
application
);
Port
(
int
port
,
const
std
::
string
&
status
,
const
std
::
string
&
owner
);
int
getPort
()
const
;
const
std
::
string
&
getStatus
()
const
;
const
std
::
string
&
get
Application
()
const
;
const
std
::
string
&
get
Owner
()
const
;
private:
int
m_port
;
std
::
string
m_status
;
std
::
string
m_
application
;
std
::
string
m_
owner
;
};
std
::
string
toString
(
cameo
::
application
::
State
applicationStates
);
...
...
include/Server.h
View file @
7a7d5a79
...
...
@@ -94,7 +94,7 @@ public:
/**
* throws ConnectionTimeout
*/
std
::
vector
<
application
::
Port
>
get
Application
Ports
()
const
;
std
::
vector
<
application
::
Port
>
getPorts
()
const
;
/**
* throws ConnectionTimeout
...
...
src/Application.cpp
View file @
7a7d5a79
...
...
@@ -1252,10 +1252,10 @@ int Info::getPid() const {
///////////////////////////////////////////////////////////////////////////
// Port
Port
::
Port
(
int
port
,
const
std
::
string
&
status
,
const
std
::
string
&
application
)
:
Port
::
Port
(
int
port
,
const
std
::
string
&
status
,
const
std
::
string
&
owner
)
:
m_port
(
port
),
m_status
(
status
),
m_
application
(
application
)
{
m_
owner
(
owner
)
{
}
int
Port
::
getPort
()
const
{
...
...
@@ -1266,8 +1266,8 @@ const std::string& Port::getStatus() const {
return
m_status
;
}
const
std
::
string
&
Port
::
get
Application
()
const
{
return
m_
application
;
const
std
::
string
&
Port
::
get
Owner
()
const
{
return
m_
owner
;
}
std
::
string
toString
(
cameo
::
application
::
State
applicationStates
)
{
...
...
@@ -1420,7 +1420,7 @@ std::ostream& operator<<(std::ostream& os, const application::Port& port) {
os
<<
"[port="
<<
port
.
m_port
<<
", status="
<<
port
.
m_status
<<
",
application
="
<<
port
.
m_
application
<<
"]"
;
<<
",
owner
="
<<
port
.
m_
owner
<<
"]"
;
return
os
;
}
...
...
src/Server.cpp
View file @
7a7d5a79
...
...
@@ -426,7 +426,7 @@ std::vector<application::Info> Server::getApplicationInfos(const std::string& na
return
infos
;
}
std
::
vector
<
application
::
Port
>
Server
::
get
Application
Ports
()
const
{
std
::
vector
<
application
::
Port
>
Server
::
getPorts
()
const
{
vector
<
application
::
Port
>
ports
;
...
...
@@ -445,9 +445,9 @@ std::vector<application::Port> Server::getApplicationPorts() const {
int
port
=
info
[
message
::
PortInfo
::
PORT
].
GetInt
();
string
status
=
info
[
message
::
PortInfo
::
STATUS
].
GetString
();
string
application
=
info
[
message
::
PortInfo
::
APPLICATION
].
GetString
();
string
owner
=
info
[
message
::
PortInfo
::
OWNER
].
GetString
();
application
::
Port
portInfo
(
port
,
status
,
application
);
application
::
Port
portInfo
(
port
,
status
,
owner
);
ports
.
push_back
(
portInfo
);
}
...
...
src/message/Message.h
View file @
7a7d5a79
...
...
@@ -302,7 +302,7 @@ namespace message {
namespace
PortInfo
{
constexpr
const
char
*
PORT
=
"port"
;
// int32
constexpr
const
char
*
STATUS
=
"status"
;
// string
constexpr
const
char
*
APPLICATION
=
"application
"
;
// string
constexpr
const
char
*
OWNER
=
"owner
"
;
// string
}
namespace
PortInfoListResponse
{
...
...
Shervin Nourbakhsh
@nourbakhsh
mentioned in commit
46e44691
·
Apr 23, 2021
mentioned in commit
46e44691
mentioned in commit 46e44691a03808a23a464818487b0dd014a9c57e
Toggle commit list
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment