mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-06-30 05:45:09 +08:00
Add replacement documenation
This commit is contained in:
parent
44af869a2c
commit
c097838614
@ -1,5 +1,15 @@
|
||||
from pathlib import Path
|
||||
|
||||
|
||||
class Replacement:
|
||||
def __init__(self, file, offset, length, replacement_text):
|
||||
def __init__(self, file: Path, offset: int, length: int, replacement_text: str):
|
||||
""" Replacement text for file between offset and offset+length.
|
||||
|
||||
@param file: File to replace text in
|
||||
@param offset: Offset in file to start text replace
|
||||
@param length: Length of text that will be replaced. offset -> offset+length is the section of text to replace.
|
||||
@param replacement_text: Text to insert of offset in file.
|
||||
"""
|
||||
self.file = file
|
||||
self.offset = offset
|
||||
self.length = length
|
||||
|
Loading…
x
Reference in New Issue
Block a user