scripts/collect_ad_boilerplate.py
def write_detector_class(boilerplate_file, dev_name, det_name, cam_name):
    """
    Writes boilerplate 'Detector' class for ophyd/areadetector/detectors.

    This script automates the creation of ophyd classes for areaDetector
    drivers by scraping their *.template files. It is called by developers as
    needed.

    Parameters
    ----------
    boilerplate_file : io.TextIOWrapper
        Open temporary file for writing boilerplate
    dev_name : str
        Name of device type/make. Ex. PICam, Eiger, etc.
    det_name : str
        Name of detector class, ex. PICamDetector, EigerDetector, etc.
    cam_name : str
        Name of cam class, ex. PICamDetectorCam, EigerDetectorCam, etc.
    """

    boilerplate_file.write(
        f'''
class {det_name}(DetectorBase):
    _html_docs = ['{dev_name}Doc.html']
    cam = C(cam.{cam_name}, 'cam1:')
''')

    Writes boilerplate 'Detector' class for ophyd/areadetector/detectors.

    This script automates the creation of ophyd classes for areaDetector
    drivers by scraping their *.template files. It is called by developers as
    needed.

    Parameters
    ----------
    boilerplate_file : io.TextIOWrapper
        Open temporary file for writing boilerplate
    dev_name : str
        Name of device type/make. Ex. PICam, Eiger, etc.
    det_name : str
        Name of detector class, ex. PICamDetector, EigerDetector, etc.
    cam_name : str
        Name of cam class, ex. PICamDetectorCam, EigerDetectorCam, etc.
    
Writes boilerplate 'Detector' class for ophyd/areadetector/detectors.
This script automates the creation of ophyd classes for areaDetector
drivers by scraping their *.template files. It is called by developers as
needed.

Parameters

boilerplate_file : io.TextIOWrapper
Open temporary file for writing boilerplate
dev_name : str
Name of device type/make. Ex.
Writes boilerplate ' Detector ' class for ophyd / areadetector / detectors . This script automates the creation of ophyd classes for areaDetector drivers by scraping their * . template files . It is called by developers as needed . Parameters boilerplate_file : io . TextIOWrapper Open temporary file for writing boilerplate dev_name : str Name of device type / make . Ex .
def write_detector_class(boilerplate_file, dev_name, det_name, cam_name):
    boilerplate_file.write(
        f'''
class {det_name}(DetectorBase):
    _html_docs = ['{dev_name}Doc.html']
    cam = C(cam.{cam_name}, 'cam1:')
''')
def write_detector_class ( boilerplate_file , dev_name , det_name , cam_name ) : boilerplate_file . write ( f'''
class {det_name}(DetectorBase):
    _html_docs = ['{dev_name}Doc.html']
    cam = C(cam.{cam_name}, 'cam1:')
''' )
Writes boilerplate 'Detector' class for ophyd/areadetector/detectors.
Writes boilerplate ' Detector ' class for ophyd / areadetector / detectors .
"""
    Writes boilerplate 'Detector' class for ophyd/areadetector/detectors.

    This script automates the creation of ophyd classes for areaDetector
    drivers by scraping their *.template files. It is called by developers as
    needed.

    Parameters
    ----------
    boilerplate_file : io.TextIOWrapper
        Open temporary file for writing boilerplate
    dev_name : str
        Name of device type/make. Ex. PICam, Eiger, etc.
    det_name : str
        Name of detector class, ex. PICamDetector, EigerDetector, etc.
    cam_name : str
        Name of cam class, ex. PICamDetectorCam, EigerDetectorCam, etc.
    """
boilerplate_file
dev_name
det_name
cam_name