Skip to content

Commit

Permalink
Improve java_error messages
Browse files Browse the repository at this point in the history
  • Loading branch information
pomadchin committed Jan 19, 2024
1 parent f43f15d commit 8530d92
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
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

0 comments on commit 8530d92

Please sign in to comment.