apache / lucenenet

Apache Lucene.NET
https://lucenenet.apache.org/
Apache License 2.0
2.24k stars 639 forks source link

Implement ISpanAppendable in CharBlockArray and CharTermAttributeImpl #1028

Closed paulirwin closed 3 days ago

paulirwin commented 5 days ago

Implement ISpanAppendable in CharBlockArray and CharTermAttributeImpl

Fixes #1026

Description

This adds ISpanAppendable to the CharBlockArray and CharTermAttributeImpl classes. The classes implement the interface explicitly so that we can provide a default implementation that returns itself rather than ISpanAppendable, to match the existing Append overloads.

Note that while IAppendable is now redundant in the interface list for these types, I left it there for Lucene source compatibility and reference, since ISpanAppendable does not exist in Lucene.

paulirwin commented 5 days ago

@NightOwl888 I intend to mark this ready for review once #1018 is merged, leaving as draft for now. I'll also likely have to resolve a merge conflict at that point too.