(self, layout_uid, placeholder_uid, workspace=None,
                 user=None, position=None)
:param string placeholder_uid: Unique identifier of plugin
            placeholder (layout.placeholder).
        :param dash.models.DashboardWorkspace workspace: Plugin workspace.
        :param django.contrib.auth.models.User user: Plugin owner.
:param string placeholder_uid: Unique identifier of plugin
            placeholder (layout.placeholder).
        :param dash.models.DashboardWorkspace workspace: Plugin workspace.
        :param django.contrib.auth.models.User user: Plugin owner.
: param string placeholder_uid : Unique identifier of plugin placeholder ( layout . placeholder ) . : param dash . models . DashboardWorkspace workspace : Plugin workspace . : param django . contrib . auth . models . User user : Plugin owner .
def __init__(self, layout_uid, placeholder_uid, workspace=None,
                 user=None, position=None):
        """
        :param string placeholder_uid: Unique identifier of plugin
            placeholder (layout.placeholder).
        :param dash.models.DashboardWorkspace workspace: Plugin workspace.
        :param django.contrib.auth.models.User user: Plugin owner.
        """
        # Making sure all necessary properties are defined.
        try:
            assert self.uid
            assert self.name
        except Exception as e:
            raise NotImplementedError(
                "You should define `uid` and `name` properties in your "
                "`{0}.{1}` class.".format(self.__class__.__module__,
                                          self.__class__.__name__)
            )

        layout_cls = layout_registry.get(layout_uid, None)
        self.layout = layout_cls() if layout_cls else None

        placeholder_cls = self.layout.get_placeholder(placeholder_uid)
        self.placeholder = placeholder_cls(self.layout) \
            if placeholder_cls \
            else None

        if not (self.layout and self.placeholder):
            raise Exception(
                "Invalid placeholder value {0} in "
                "your `{1}.{2}` class.".format(
                    placeholder_uid,
                    self.__class__.__module__,
                    self.__class__.__name__
                )
            )

        self.layout_uid = layout_uid
        self.placeholder_uid = placeholder_uid
        self.workspace = workspace
        self.user = user
        self.position = position

        # Some initial values
        self.request = None

        self.data = DashboardPluginDataStorage()

        self._html_id = 'p{0}'.format(uuid.uuid4())
def __init__ ( self , layout_uid , placeholder_uid , workspace = None , user = None , position = None ) : # Making sure all necessary properties are defined. try : assert self . uid assert self . name except Exception as e : raise NotImplementedError ( "You should define `uid` and `name` properties in your " "`{0}.{1}` class." . format ( self . __class__ . __module__ , self . __class__ . __name__ ) ) layout_cls = layout_registry . get ( layout_uid , None ) self . layout = layout_cls ( ) if layout_cls else None placeholder_cls = self . layout . get_placeholder ( placeholder_uid ) self . placeholder = placeholder_cls ( self . layout ) if placeholder_cls else None if not ( self . layout and self . placeholder ) : raise Exception ( "Invalid placeholder value {0} in " "your `{1}.{2}` class." . format ( placeholder_uid , self . __class__ . __module__ , self . __class__ . __name__ ) ) self . layout_uid = layout_uid self . placeholder_uid = placeholder_uid self . workspace = workspace self . user = user self . position = position # Some initial values self . request = None self . data = DashboardPluginDataStorage ( ) self . _html_id = 'p{0}' . format ( uuid . uuid4 ( ) )