Java: no namespace indent
This commit is contained in:
parent
a52ce7bb7b
commit
f58c14a74a
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2018 Max Kellermann <max.kellermann@gmail.com>
|
||||
* Copyright 2010-2021 Max Kellermann <max.kellermann@gmail.com>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
@ -36,6 +36,7 @@
|
||||
#include <cassert>
|
||||
|
||||
namespace Java {
|
||||
|
||||
/**
|
||||
* Wrapper for a local "jclass" reference.
|
||||
*/
|
||||
@ -77,6 +78,7 @@ namespace Java {
|
||||
return true;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
} // namespace Java
|
||||
|
||||
#endif
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2019 Max Kellermann <max.kellermann@gmail.com>
|
||||
* Copyright 2010-2021 Max Kellermann <max.kellermann@gmail.com>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2019 Max Kellermann <max.kellermann@gmail.com>
|
||||
* Copyright 2010-2021 Max Kellermann <max.kellermann@gmail.com>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
@ -35,6 +35,7 @@
|
||||
#include <jni.h>
|
||||
|
||||
namespace Java {
|
||||
|
||||
class Exception : public std::runtime_error {
|
||||
public:
|
||||
explicit Exception(JNIEnv *env, jthrowable e) noexcept;
|
||||
@ -57,6 +58,7 @@ namespace Java {
|
||||
env->ExceptionClear();
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace Java
|
||||
|
||||
#endif
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2018 Max Kellermann <max.kellermann@gmail.com>
|
||||
* Copyright 2010-2021 Max Kellermann <max.kellermann@gmail.com>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
@ -37,6 +37,7 @@
|
||||
class AllocatedPath;
|
||||
|
||||
namespace Java {
|
||||
|
||||
/**
|
||||
* Wrapper for a java.io.File object.
|
||||
*/
|
||||
@ -61,6 +62,7 @@ namespace Java {
|
||||
static AllocatedPath ToAbsolutePath(JNIEnv *env,
|
||||
jobject file) noexcept;
|
||||
};
|
||||
}
|
||||
|
||||
} // namespace Java
|
||||
|
||||
#endif
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2018 Max Kellermann <max.kellermann@gmail.com>
|
||||
* Copyright 2010-2021 Max Kellermann <max.kellermann@gmail.com>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
@ -30,10 +30,12 @@
|
||||
#include "Global.hxx"
|
||||
|
||||
namespace Java {
|
||||
|
||||
JavaVM *jvm;
|
||||
|
||||
void Init(JNIEnv *env) noexcept
|
||||
{
|
||||
env->GetJavaVM(&jvm);
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace Java
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2018 Max Kellermann <max.kellermann@gmail.com>
|
||||
* Copyright 2010-2021 Max Kellermann <max.kellermann@gmail.com>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
@ -35,6 +35,7 @@
|
||||
#include <jni.h>
|
||||
|
||||
namespace Java {
|
||||
|
||||
extern JavaVM *jvm;
|
||||
|
||||
void Init(JNIEnv *env) noexcept;
|
||||
@ -53,6 +54,7 @@ namespace Java {
|
||||
jvm->AttachCurrentThread(&env, nullptr);
|
||||
return env;
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace Java
|
||||
|
||||
#endif
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2019 Max Kellermann <max.kellermann@gmail.com>
|
||||
* Copyright 2010-2021 Max Kellermann <max.kellermann@gmail.com>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
@ -37,6 +37,7 @@
|
||||
#include <cassert>
|
||||
|
||||
namespace Java {
|
||||
|
||||
/**
|
||||
* Wrapper for a local "jobject" reference.
|
||||
*/
|
||||
@ -71,6 +72,7 @@ namespace Java {
|
||||
return (jstring)env->CallObjectMethod(o, toString_method);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
} // namespace Java
|
||||
|
||||
#endif
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2018 Max Kellermann <max.kellermann@gmail.com>
|
||||
* Copyright 2010-2021 Max Kellermann <max.kellermann@gmail.com>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
@ -38,6 +38,7 @@
|
||||
#include <utility>
|
||||
|
||||
namespace Java {
|
||||
|
||||
/**
|
||||
* Hold a local reference on a JNI object.
|
||||
*/
|
||||
@ -202,6 +203,7 @@ namespace Java {
|
||||
return value;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
} // namespace Java
|
||||
|
||||
#endif
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2019 Max Kellermann <max.kellermann@gmail.com>
|
||||
* Copyright 2010-2021 Max Kellermann <max.kellermann@gmail.com>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
@ -38,6 +38,7 @@
|
||||
#include <string>
|
||||
|
||||
namespace Java {
|
||||
|
||||
/**
|
||||
* Wrapper for a local "jstring" reference.
|
||||
*/
|
||||
@ -77,6 +78,7 @@ namespace Java {
|
||||
return ToString(GetEnv(), Get());
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
} // namespace Java
|
||||
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user