class AWS::EC2::ElasticIp

def associated?

Returns:
  • (Boolean) - Returns true if this IP address is attached to
def associated?
  !!instance_id
end