<commit_before>from zope.interface import Interface, Attribute


class IDriver(Interface):
    """
    TODO
    
    A Driver represents an interface to a provider Web Service. This is the
    Interface which all base drivers (`EC2Driver`, `SliceDriver`, etc.) should
    implement!
    """
    connectionCls = Attribute("""A suitable provider-specific Connection class""")
    nodesCls = Attribute("""A suitable provider-specific NodeDriver class""")
    connection = Attribute("""A suitable provider-specific Connection instance""")
    nodes = Attribute("""A suitable provider-specific NodeDriver instance""")


class IDriverFactory(Interface):
    """
    TODO

    Creates IDrivers
    """
    def __call__():
        """
        Initialize `connection` and `nodes` 
        """


class INodeDriver(Interface):
  """
  A driver which provides nodes, such as an Amazon EC2 instance, or Slicehost slice
  """

  def create_node(node):
    """
    Creates a new node based on the given skeleton node
    """

  def destroy_node(node):
    """
    Destroys (shuts down) the given node
    """

  def list_nodes():
    """
    Returns a list of nodes for this provider
    """
  
  def reboot_node(node):
    """
    Reboots the given node
    """<commit_msg>Renamed INodeDriver methods to remove redundancy ('node' is implied)<commit_after>from zope.interface import Interface, Attribute


class IDriver(Interface):
    """
    TODO
    
    A Driver represents an interface to a provider Web Service. This is the
    Interface which all base drivers (`EC2Driver`, `SliceDriver`, etc.) should
    implement!
    """
    connectionCls = Attribute("""A suitable provider-specific Connection class""")
    nodesCls = Attribute("""A suitable provider-specific NodeDriver class""")
    connection = Attribute("""A suitable provider-specific Connection instance""")
    nodes = Attribute("""A suitable provider-specific NodeDriver instance""")


class IDriverFactory(Interface):
    """
    TODO

    Creates IDrivers
    """
    def __call__():
        """
        Initialize `connection` and `nodes` 
        """


class INodeDriver(Interface):
  """
  A driver which provides nodes, such as an Amazon EC2 instance, or Slicehost slice
  """

  def create(node):
    """
    Creates a new node based on the given skeleton node
    """

  def destroy(node):
    """
    Destroys (shuts down) the given node
    """

  def list():
    """
    Returns a list of nodes for this provider
    """

  def reboot(node):
    """
    Reboots the given node
    """
{'fraction_non_alphanumeric': 0.10823529411764705, 'fraction_numerical': 0.001568627450980392, 'mean_word_length': 3.0816, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1318633', 'n_tokens_mistral': 697, 'n_tokens_neox': 675, 'n_words': 244}