Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve java_error messages #80

Merged
merged 1 commit into from
Jan 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions native/src/JavaPipeline.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ string PipelineExecutor::getSchema() const
MetadataNode computePreview(Stage* stage)
{
if (!stage)
throw java_error("no valid stage in QuickInfo");
throw java_error("No valid stage in QuickInfo");

stage->preview();

Expand Down Expand Up @@ -229,7 +229,7 @@ void PipelineExecutor::setLogStream(std::ostream& strm)
void PipelineExecutor::setLogLevel(int level)
{
if (level < static_cast<int>(LogLevel::Error) || level > static_cast<int>(LogLevel::None))
throw java_error("log level must be between 0 and 9!");
throw java_error("LogLevel should be between 0 and 9");

m_logLevel = static_cast<pdal::LogLevel>(level);
setLogStream(m_logStream);
Expand Down
2 changes: 1 addition & 1 deletion native/src/include/JavaSetIterator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ class JavaSetIterator {
}
K next() {
if(!hasNext())
throw java_error("iterator is out of bounds");
throw java_error("Iterator is out of bounds");

return *std::next(container.begin(), curr_pos++);
}
Expand Down
2 changes: 1 addition & 1 deletion native/src/include/JavaTriangularMeshIterator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class TriangularMeshIterator {
}
Triangle next() {
if(!hasNext())
throw java_error("iterator is out of bounds");
throw java_error("Iterator is out of bounds");

return *std::next(container.begin(), curr_pos++);
}
Expand Down
Loading