build: fix cpp formatting

This commit is contained in:
Alexander Capehart 2024-12-26 18:38:38 -05:00
parent 8d49893309
commit 5e7d575efd
No known key found for this signature in database
GPG key ID: 37DBE3621FE9AD47
11 changed files with 362 additions and 299 deletions

View file

@ -43,8 +43,8 @@ spotless {
} }
cpp { cpp {
target "*/src/**/cpp/*.cpp" target("*/src/**/cpp/*.cpp", "*/src/**/cpp/*.h", "*/src/**/cpp/*.hpp")
eclipseCdt() eclipseCdt().configFile("eclipse-cdt.xml")
licenseHeaderFile("NOTICE") licenseHeaderFile("NOTICE")
} }
} }

8
eclipse-cdt.xml Normal file
View file

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<profiles version="12">
<profile kind="CodeFormatterProfile" name="CustomProfile" version="12">
<setting id="org.eclipse.cdt.core.formatter.tabulation.char" value="space"/>
<setting id="org.eclipse.cdt.core.formatter.tabulation.size" value="4"/>
<setting id="org.eclipse.cdt.core.formatter.indentation.size" value="4"/>
</profile>
</profiles>

View file

@ -1,4 +1,5 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"> <manifest
xmlns:android="http://schemas.android.com/apk/res/android">
</manifest> </manifest>

View file

@ -1,6 +1,20 @@
// /*
// Created by oxycblt on 12/12/24. * Copyright (c) 2024 Auxio Project
// * JVMInputStream.h is part of Auxio.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
#ifndef AUXIO_JVMINPUTSTREAM_H #ifndef AUXIO_JVMINPUTSTREAM_H
#define AUXIO_JVMINPUTSTREAM_H #define AUXIO_JVMINPUTSTREAM_H
@ -9,14 +23,14 @@
#include "taglib/tiostream.h" #include "taglib/tiostream.h"
class JVMInputStream : public TagLib::IOStream { class JVMInputStream: public TagLib::IOStream {
public: public:
JVMInputStream(JNIEnv *env, jobject inputStream); JVMInputStream(JNIEnv *env, jobject inputStream);
~JVMInputStream(); ~JVMInputStream();
JVMInputStream(const JVMInputStream &) = delete; JVMInputStream(const JVMInputStream&) = delete;
JVMInputStream &operator=(const JVMInputStream &) = delete; JVMInputStream& operator=(const JVMInputStream&) = delete;
/*! /*!
* Returns the stream name in the local file system encoding. * Returns the stream name in the local file system encoding.
@ -46,8 +60,8 @@ public:
* \note This method is slow since it requires rewriting all of the file * \note This method is slow since it requires rewriting all of the file
* after the insertion point. * after the insertion point.
*/ */
void insert(const TagLib::ByteVector &data, void insert(const TagLib::ByteVector &data, TagLib::offset_t start = 0,
TagLib::offset_t start = 0, size_t replace = 0) override; size_t replace = 0) override;
/*! /*!
* Removes a block of the file starting a \a start and continuing for * Removes a block of the file starting a \a start and continuing for
@ -110,5 +124,4 @@ private:
}; };
#endif //AUXIO_JVMINPUTSTREAM_H #endif //AUXIO_JVMINPUTSTREAM_H

View file

@ -1,6 +1,20 @@
// /*
// Created by oxycblt on 12/12/24. * Copyright (c) 2024 Auxio Project
// * JVMMetadataBuilder.h is part of Auxio.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
#ifndef AUXIO_JVMMETADATABUILDER_H #ifndef AUXIO_JVMMETADATABUILDER_H
#define AUXIO_JVMMETADATABUILDER_H #define AUXIO_JVMMETADATABUILDER_H

View file

@ -1,6 +1,20 @@
// /*
// Created by oxycblt on 12/12/24. * Copyright (c) 2024 Auxio Project
// * JVMTagMap.h is part of Auxio.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
#ifndef AUXIO_JVMTAGMAP_H #ifndef AUXIO_JVMTAGMAP_H
#define AUXIO_JVMTAGMAP_H #define AUXIO_JVMTAGMAP_H
@ -15,8 +29,8 @@ public:
JVMTagMap(JNIEnv *env); JVMTagMap(JNIEnv *env);
~JVMTagMap(); ~JVMTagMap();
JVMTagMap(const JVMTagMap &) = delete; JVMTagMap(const JVMTagMap&) = delete;
JVMTagMap &operator=(const JVMTagMap &) = delete; JVMTagMap& operator=(const JVMTagMap&) = delete;
void add(TagLib::String &key, std::string_view value); void add(TagLib::String &key, std::string_view value);
void add(TagLib::String &key, TagLib::StringList &value); void add(TagLib::String &key, TagLib::StringList &value);
@ -32,5 +46,4 @@ private:
jmethodID arrayListAddMethod; jmethodID arrayListAddMethod;
}; };
#endif //AUXIO_JVMTAGMAP_H #endif //AUXIO_JVMTAGMAP_H

View file

@ -1,6 +1,20 @@
// /*
// Created by oxycblt on 12/23/24. * Copyright (c) 2024 Auxio Project
// * log.h is part of Auxio.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
#ifndef AUXIO_LOG_H #ifndef AUXIO_LOG_H
#define AUXIO_LOG_H #define AUXIO_LOG_H