Go to the documentation of this file.
49 const char* kOuterClassNameSuffix =
"OuterClass";
58 if (file->package().empty()) {
62 return full_name.substr(file->package().size() + 1);
77 if (message_descriptor ==
NULL) {
80 return ClassNameWithoutPackage(message_descriptor, immutable) +
"." +
110 if (CheckNameEquality(
message->name(), classname) == equality_mode) {
113 for (
int i = 0;
i <
message->nested_type_count(); ++
i) {
114 if (MessageHasConflictingClassName(
message->nested_type(
i), classname,
119 for (
int i = 0;
i <
message->enum_type_count(); ++
i) {
120 if (CheckNameEquality(
message->enum_type(
i)->name(), classname) ==
137 std::string::size_type last_slash = file->
name().find_last_of(
'/');
138 if (last_slash == std::string::npos) {
139 basename = file->
name();
141 basename = file->
name().substr(last_slash + 1);
149 if (class_name.empty()) {
150 if (file->
options().has_java_outer_classname()) {
156 class_name += kOuterClassNameSuffix;
184 if (CheckNameEquality(file->
service(
i)->
name(), classname) ==
190 if (MessageHasConflictingClassName(file->
message_type(
i), classname,
206 if (!result.empty()) result +=
'.';
215 bool immutable,
bool multiple_files) {
217 if (multiple_files) {
222 if (!result.empty()) {
225 result += name_without_package;
257 if (!result.empty()) result +=
'.';
260 if (!result.empty()) result +=
'$';
262 result +=
StringReplace(name_without_package,
".",
"$",
true);
std::string UnderscoresToCamelCase(const std::string &input, bool cap_next_letter)
const EnumDescriptor * enum_type(int index) const
std::map< const FileDescriptor *, std::string > file_immutable_outer_class_names_
bool MultipleJavaFiles(const FileDescriptor *descriptor, bool immutable)
std::string GetExtensionIdentifierName(const FieldDescriptor *descriptor, bool immutable)
GLsizei const GLchar *const * string
const std::string & name() const
std::string GetClassFullName(const std::string &name_without_package, const FileDescriptor *file, bool immutable, bool multiple_files)
int enum_type_count() const
GLboolean GLboolean GLboolean b
const std::string & name() const
std::string GetFileImmutableClassName(const FileDescriptor *file)
const ServiceDescriptor * service(int index) const
std::string GetJavaClassFullName(const std::string &name_without_package, const FileDescriptor *file, bool immutable)
std::string GetFileClassName(const FileDescriptor *file, bool immutable)
const FileOptions & options() const
std::string FileJavaPackage(const FileDescriptor *file, bool immutable)
#define GOOGLE_CHECK(EXPRESSION)
std::string GetJavaImmutableClassName(const Descriptor *descriptor)
const std::string & java_outer_classname() const
const std::string & name() const
void StringReplace(const string &s, const string &oldsub, const string &newsub, bool replace_all, string *res)
const Descriptor * message_type(int index) const
int service_count() const
string ToUpper(const string &s)
std::string StripProto(const std::string &filename)
std::string GetClassName(const Descriptor *descriptor, bool immutable)
std::string GetDescriptorClassName(const FileDescriptor *file)
bool HasConflictingClassName(const FileDescriptor *file, const std::string &classname, NameEquality equality_mode)
std::string GetFileDefaultImmutableClassName(const FileDescriptor *file)
GLboolean GLboolean GLboolean GLboolean a
int message_type_count() const
GLenum GLuint GLenum GLsizei const GLchar * message
libaditof
Author(s):
autogenerated on Wed May 21 2025 02:06:55