FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
git2cpp/src/wrapper/annotated_commit_wrapper.cpp at 0.0.12 · QuantStack/git2cpp · GitHub
QuantStack
git2cpp
Repository navigation
Code
Issues
6
(6)
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
git2cpp
/
src
/
wrapper
/
annotated_commit_wrapper.cpp
Copy path
More file actions
More file actions
Latest commit
History
History
History
29 lines (24 loc) · 731 Bytes
Breadcrumbs
git2cpp
/
src
/
wrapper
/
annotated_commit_wrapper.cpp
Copy path
File metadata and controls
29 lines (24 loc) · 731 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#
include
"
../wrapper/annotated_commit_wrapper.hpp
"
annotated_commit_wrapper::annotated_commit_wrapper
(git_annotated_commit* commit)
: base_type(commit)
{
}
annotated_commit_wrapper::~annotated_commit_wrapper
()
{
git_annotated_commit_free
(p_resource);
p_resource =
nullptr
;
}
const
git_oid&
annotated_commit_wrapper::oid
()
const
{
return
*
git_annotated_commit_id
(p_resource);
}
std::string
annotated_commit_wrapper::commit_oid_tostr
()
const
{
char
buf[
GIT_OID_SHA1_HEXSIZE
+
1
];
return
git_oid_tostr
(buf,
sizeof
(buf), &
this
->
oid
());
}
std::string_view
annotated_commit_wrapper::reference_name
()
const
{
const
char
* res =
git_annotated_commit_ref
(*
this
);
return
res ? res : std::string_view{};
}
Back
|
FazBrowse Home
|
New Git URL