# Path: pygls/lsp/types/basic_structures.py
# class Model(BaseModel):
#     class Config:
#         alias_generator = snake_to_camel
#         allow_population_by_field_name = True
#         fields = {
#             'from_': 'from'
#         }
# 
# class PartialResultParams(Model):
#     partial_result_token: Optional[ProgressToken]
# 
# class Range(Model):
#     start: Position
#     end: Position
# 
#     def __eq__(self, other):
#         return (
#             isinstance(other, Range)
#             and self.start == other.start
#             and self.end == other.end)
# 
#     def __hash__(self):
#         return hash((self.start, self.end))
# 
#     def __iter__(self):
#         return iter((self.start, self.end))
# 
#     def __repr__(self):
#         return f'{self.start!r}-{self.end!r}'
# 
# class TextDocumentIdentifier(Model):
#     uri: str
# 
# class TextEdit(Model):
#     range: Range
#     new_text: str
# 
# class WorkDoneProgressParams(Model):
#     work_done_token: Optional[ProgressToken]
# 
# Path: pygls/lsp/types/language_features/document_color.py
# class Color(Model):
#     red: float
#     green: float
#     blue: float
#     alpha: float


from typing import List, Optional
from pygls.lsp.types.basic_structures import (Model, PartialResultParams, Range,
                                              TextDocumentIdentifier, TextEdit,
                                              WorkDoneProgressParams)
from pygls.lsp.types.language_features.document_color import Color
# You may obtain a copy of the License at                                  #
#                                                                          #
#     http: // www.apache.org/licenses/LICENSE-2.0                         #
#                                                                          #
# Unless required by applicable law or agreed to in writing, software      #
# distributed under the License is distributed on an "AS IS" BASIS,        #
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
# See the License for the specific language governing permissions and      #
# limitations under the License.                                           #
############################################################################
"""This module contains Language Server Protocol types
https://microsoft.github.io/language-server-protocol/specification

-- Language Features - Color Presentation --

Class attributes are named with camel case notation because client is expecting
that.
"""



class ColorPresentationParams(WorkDoneProgressParams, PartialResultParams):
    text_document: TextDocumentIdentifier
    color: Color
    range: Range


class ColorPresentation(Model):
    label: str
    text_edit: Optional[TextEdit]

# Path: pygls/lsp/types/basic_structures.py
# class Model(BaseModel):
#     class Config:
#         alias_generator = snake_to_camel
#         allow_population_by_field_name = True
#         fields = {
#             'from_': 'from'
#         }
# 
# class PartialResultParams(Model):
#     partial_result_token: Optional[ProgressToken]
# 
# class Range(Model):
#     start: Position
#     end: Position
# 
#     def __eq__(self, other):
#         return (
#             isinstance(other, Range)
#             and self.start == other.start
#             and self.end == other.end)
# 
#     def __hash__(self):
#         return hash((self.start, self.end))
# 
#     def __iter__(self):
#         return iter((self.start, self.end))
# 
#     def __repr__(self):
#         return f'{self.start!r}-{self.end!r}'
# 
# class TextDocumentIdentifier(Model):
#     uri: str
# 
# class TextEdit(Model):
#     range: Range
#     new_text: str
# 
# class WorkDoneProgressParams(Model):
#     work_done_token: Optional[ProgressToken]
# 
# Path: pygls/lsp/types/language_features/document_color.py
# class Color(Model):
#     red: float
#     green: float
#     blue: float
#     alpha: float


# Path: pygls/lsp/types/language_features/color_presentation.py
from typing import List, Optional
from pygls.lsp.types.basic_structures import (Model, PartialResultParams, Range,
                                              TextDocumentIdentifier, TextEdit,
                                              WorkDoneProgressParams)
from pygls.lsp.types.language_features.document_color import Color

# You may obtain a copy of the License at                                  #
#                                                                          #
#     http: // www.apache.org/licenses/LICENSE-2.0                         #
#                                                                          #
# Unless required by applicable law or agreed to in writing, software      #
# distributed under the License is distributed on an "AS IS" BASIS,        #
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
# See the License for the specific language governing permissions and      #
# limitations under the License.                                           #
############################################################################
"""This module contains Language Server Protocol types
https://microsoft.github.io/language-server-protocol/specification

-- Language Features - Color Presentation --

Class attributes are named with camel case notation because client is expecting
that.
"""



class ColorPresentationParams(WorkDoneProgressParams, PartialResultParams):
    text_document: TextDocumentIdentifier
    color: Color
    range: Range


class ColorPresentation(Model):
    label: str
    text_edit: Optional[TextEdit]

    additional_text_edits: Optional[List[TextEdit]]