mirror of
https://github.com/unidoc/unipdf.git
synced 2025-05-02 22:17:06 +08:00
Fixed some comments
This commit is contained in:
parent
fa19666a38
commit
7af97fba6a
@ -192,7 +192,7 @@ func GetString(obj PdfObject) (string, error) {
|
|||||||
return "", err
|
return "", err
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetString returns the bytes represented by `obj` if `obj` is a PdfObjectString or an error if it isn't.
|
// GetStringBytes returns the bytes represented by `obj` if `obj` is a PdfObjectString or an error if it isn't.
|
||||||
func GetStringBytes(obj PdfObject) ([]byte, error) {
|
func GetStringBytes(obj PdfObject) ([]byte, error) {
|
||||||
if s, ok := obj.(*PdfObjectString); ok {
|
if s, ok := obj.(*PdfObjectString); ok {
|
||||||
return []byte(*s), nil
|
return []byte(*s), nil
|
||||||
@ -201,7 +201,7 @@ func GetStringBytes(obj PdfObject) ([]byte, error) {
|
|||||||
return []byte{}, err
|
return []byte{}, err
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetString returns the string represented by `obj` if `obj` is a PdfObjectName or an error if it isn't.
|
// GetName returns the string represented by `obj` if `obj` is a PdfObjectName or an error if it isn't.
|
||||||
func GetName(obj PdfObject) (string, error) {
|
func GetName(obj PdfObject) (string, error) {
|
||||||
if s, ok := obj.(*PdfObjectName); ok {
|
if s, ok := obj.(*PdfObjectName); ok {
|
||||||
return string(*s), nil
|
return string(*s), nil
|
||||||
|
Loading…
x
Reference in New Issue
Block a user