Path: blob/master/Utilities/cmlibarchive/libarchive/archive_entry_locale.h
3153 views
/*-1* Copyright (c) 2011 Michihiro NAKAJIMA2* All rights reserved.3*4* Redistribution and use in source and binary forms, with or without5* modification, are permitted provided that the following conditions6* are met:7* 1. Redistributions of source code must retain the above copyright8* notice, this list of conditions and the following disclaimer.9* 2. Redistributions in binary form must reproduce the above copyright10* notice, this list of conditions and the following disclaimer in the11* documentation and/or other materials provided with the distribution.12*13* THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR14* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES15* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.16* IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT,17* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT18* NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,19* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY20* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT21* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF22* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.23*/2425#ifndef ARCHIVE_ENTRY_LOCALE_H_INCLUDED26#define ARCHIVE_ENTRY_LOCALE_H_INCLUDED2728#ifndef __LIBARCHIVE_BUILD29#error This header is only to be used internally to libarchive.30#endif3132struct archive_entry;33struct archive_string_conv;3435/*36* Utility functions to set and get entry attributes by translating37* character-set. These are designed for use in format readers and writers.38*39* The return code and interface of these are quite different from other40* functions for archive_entry defined in archive_entry.h.41* Common return code are:42* Return 0 if the string conversion succeeded.43* Return -1 if the string conversion failed.44*/4546#define archive_entry_gname_l _archive_entry_gname_l47int _archive_entry_gname_l(struct archive_entry *,48const char **, size_t *, struct archive_string_conv *);49#define archive_entry_hardlink_l _archive_entry_hardlink_l50int _archive_entry_hardlink_l(struct archive_entry *,51const char **, size_t *, struct archive_string_conv *);52#define archive_entry_pathname_l _archive_entry_pathname_l53int _archive_entry_pathname_l(struct archive_entry *,54const char **, size_t *, struct archive_string_conv *);55#define archive_entry_symlink_l _archive_entry_symlink_l56int _archive_entry_symlink_l(struct archive_entry *,57const char **, size_t *, struct archive_string_conv *);58#define archive_entry_uname_l _archive_entry_uname_l59int _archive_entry_uname_l(struct archive_entry *,60const char **, size_t *, struct archive_string_conv *);61#define archive_entry_acl_text_l _archive_entry_acl_text_l62int _archive_entry_acl_text_l(struct archive_entry *, int,63const char **, size_t *, struct archive_string_conv *) __LA_DEPRECATED;64#define archive_entry_acl_to_text_l _archive_entry_acl_to_text_l65char *_archive_entry_acl_to_text_l(struct archive_entry *, ssize_t *, int,66struct archive_string_conv *);67#define archive_entry_acl_from_text_l _archive_entry_acl_from_text_l68int _archive_entry_acl_from_text_l(struct archive_entry *, const char* text,69int type, struct archive_string_conv *);70#define archive_entry_copy_gname_l _archive_entry_copy_gname_l71int _archive_entry_copy_gname_l(struct archive_entry *,72const char *, size_t, struct archive_string_conv *);73#define archive_entry_copy_hardlink_l _archive_entry_copy_hardlink_l74int _archive_entry_copy_hardlink_l(struct archive_entry *,75const char *, size_t, struct archive_string_conv *);76#define archive_entry_copy_link_l _archive_entry_copy_link_l77int _archive_entry_copy_link_l(struct archive_entry *,78const char *, size_t, struct archive_string_conv *);79#define archive_entry_copy_pathname_l _archive_entry_copy_pathname_l80int _archive_entry_copy_pathname_l(struct archive_entry *,81const char *, size_t, struct archive_string_conv *);82#define archive_entry_copy_symlink_l _archive_entry_copy_symlink_l83int _archive_entry_copy_symlink_l(struct archive_entry *,84const char *, size_t, struct archive_string_conv *);85#define archive_entry_copy_uname_l _archive_entry_copy_uname_l86int _archive_entry_copy_uname_l(struct archive_entry *,87const char *, size_t, struct archive_string_conv *);8889#endif /* ARCHIVE_ENTRY_LOCALE_H_INCLUDED */909192