Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Core » XmlParser::IsEnd() should be declared as const
XmlParser::IsEnd() should be declared as const [message #50477] Tue, 06 November 2018 15:54 Go to next message
Novo is currently offline  Novo
Messages: 889
Registered: December 2006
Experienced Contributor
SUBJ.
All other XmlParser::IsXXX() methods should be declared as const as well.
Otherwise you have to use a non-const object which is in reality doesn't change any data.

Just my 2 cents.


Regards,
Novo
Re: XmlParser::IsEnd() should be declared as const [message #50480 is a reply to message #50477] Tue, 06 November 2018 18:17 Go to previous message
mirek is currently offline  mirek
Messages: 12017
Registered: November 2005
Ultimate Member
Novo wrote on Tue, 06 November 2018 15:54
SUBJ.
All other XmlParser::IsXXX() methods should be declared as const as well.
Otherwise you have to use a non-const object which is in reality doesn't change any data.

Just my 2 cents.


Generally you are right. Here it is not const because some future implementation might need to read input stream for IsEnd, thus changing internal sttate.
Previous Topic: [SOLVED]Some modifications for WebSocket only as Client
Next Topic: LRUCache has the GetLRU () method, but does not have GetLRUKey()
Goto Forum:
  


Current Time: Wed Sep 18 07:39:03 CEST 2019

Total time taken to generate the page: 0.01415 seconds