# Path: wham/fields.py
# class WhamTextField(WhamFieldMixin, models.TextField):
# 
#     @property
#     def type_repr(self):
#         return 'text'
# 
# class WhamIntegerField(WhamFieldMixin, models.IntegerField):
# 
#     @property
#     def type_repr(self):
#         return 'integer'
# 
# Path: wham/models.py
# class WhamModel(models.Model):
# 
#     objects = WhamManager()
# 
#     class Meta():
#         abstract = True


from django.db import models
from django.db import models
from wham.fields import WhamTextField, WhamIntegerField
from wham.models import WhamModel

# Create your models here.

# http://api.soundcloud.com/tracks/13158665.json?client_id=a43d27e75fbd64533f57428dd7be3ba5



class SoundcloudMeta:
    base_url = 'http://api.soundcloud.com/'
    auth_for_public_get = 'API_KEY'
    api_key_settings_name = 'SOUNDCLOUD_CLIENT_ID'
    api_key_param = 'client_id'

class SoundcloudTrack(WhamModel):

    id = models.CharField(max_length=255, primary_key=True)
    title = WhamTextField()

    track_type = WhamTextField(null=True)
    stream_url = WhamTextField(null=True)

# Path: wham/fields.py
# class WhamTextField(WhamFieldMixin, models.TextField):
# 
#     @property
#     def type_repr(self):
#         return 'text'
# 
# class WhamIntegerField(WhamFieldMixin, models.IntegerField):
# 
#     @property
#     def type_repr(self):
#         return 'integer'
# 
# Path: wham/models.py
# class WhamModel(models.Model):
# 
#     objects = WhamManager()
# 
#     class Meta():
#         abstract = True


# Path: wham/apis/soundcloud/models.py
from django.db import models
from django.db import models
from wham.fields import WhamTextField, WhamIntegerField
from wham.models import WhamModel


# Create your models here.

# http://api.soundcloud.com/tracks/13158665.json?client_id=a43d27e75fbd64533f57428dd7be3ba5



class SoundcloudMeta:
    base_url = 'http://api.soundcloud.com/'
    auth_for_public_get = 'API_KEY'
    api_key_settings_name = 'SOUNDCLOUD_CLIENT_ID'
    api_key_param = 'client_id'

class SoundcloudTrack(WhamModel):

    id = models.CharField(max_length=255, primary_key=True)
    title = WhamTextField()

    track_type = WhamTextField(null=True)
    stream_url = WhamTextField(null=True)

    playback_count = WhamIntegerField(null=True)