Add a method to get the tracking url of an object.
174883
def _add_get_tracking_url(cls):
    
    def get_tracking_url(self):
        """ return url to tracking view in admin panel """
        url = reverse('admin:tracking_fields_trackingevent_changelist')
        object_id = '{0}%3A{1}'.format(
            ContentType.objects.get_for_model(self).pk,
            self.pk
        )
        return '{0}?object={1}'.format(url, object_id)
    if not hasattr(cls, 'get_tracking_url'):
        setattr(cls, 'get_tracking_url', get_tracking_url)
46608
def Get_Page(self):
		'''
			
		'''
		url = 'http://www.gati.com/webservices/gatiicedkttrack.jsp?dktno=' + self.tracking_no
		response = requests.get(url)

		self.page = response.text
1047365
def get(self, request, path=None, **resources):
        
        tracker = Tracker(
            self._meta.account_id,
            self._meta.domain or request.META.get('SERVER_NAME'))
        visitor = Visitor()
        visitor.extract_from_server_meta(request.META)
        session = Session()
        page = Page(path)
        tracker.track_pageview(page, session, visitor)
1092493
public static Trajectory getTrajectoryByID(List<? extends Trajectory> t, int id){
		Trajectory track = null;
		for(int i = 0; i < t.size() ; i++){
			if(t.get(i).getID()==id){
				track = t.get(i);
				break;
			}
		}
		return track;
	}
350265
function HTTPTracker (client, announceUrl, opts) {
  var self = this
  Tracker.call(self, client, announceUrl)
  debug('new http tracker %s', announceUrl)

  // Determine scrape url (if http tracker supports it)
  self.scrapeUrl = null

  var match = self.announceUrl.match(HTTP_SCRAPE_SUPPORT)
  if (match) {
    var pre = self.announceUrl.slice(0, match.index)
    var post = self.announceUrl.slice(match.index + 9)
    self.scrapeUrl = pre + '/scrape' + post
  }

  self.cleanupFns = []
  self.maybeDestroyCleanup = null
}
1330440
def endpoint(url, method="GET", expected_status=200):
    
    def dec(obj):
        obj.ENDPOINT = url
        obj.METHOD = method
        obj.EXPECTED_STATUS = expected_status
        return obj

    return dec
983320
def get_object_url(self):
        

        if self.kwargs.get(self.slug_url_kwarg, False) == \
                    unicode(getattr(self.object, self.slug_field, "")) \
                    and not self.force_add:
            url = self.request.build_absolute_uri()
        else:
            url = self.bundle.get_view_url('edit', self.request.user,
                                           {'object': self.object},
                                           self.kwargs)
        return url
1117898
function (obj) {
                shared.utils.dassert(getTracker(obj) === this);
                this._rev += 1;
                this._type = shared.types.TypeStore.instance().type(obj);
            }
690036
def _location(self, obj):
        
        field_name = self.clean_id_name
        return self.request.route_url(
            self._resource.uid,
            **{self._resource.id_name: getattr(obj, field_name)})
592714
def get_uri(self, action, obj=None, date=None):
        
        if date is None:
            date = action.timestamp
        date = datetime_safe.new_datetime(date).strftime('%Y-%m-%d')
        return 'tag:%s,%s:%s' % (Site.objects.get_current().domain, date,
                                 self.get_url(action, obj, False))
1210768
@Override
  public String getTrackingUrl() {
    if (this.httpServer == null) {
      return "";
    }

    try {
      return InetAddress.getLocalHost().getHostAddress() + ":" + httpServer.getPort();
    } catch (final UnknownHostException e) {
      LOG.log(Level.WARNING, "Cannot get host address.", e);
      throw new RuntimeException("Cannot get host address.", e);
    }
  }
1360340
function PostNLInfo(obj) {
    this.id = obj.id
    this.state = obj.states[0].state
    this.states = obj.states
    this.trackerWebsite = postNL.getLink(null)
}
1301861
public static Tracker parseTracker(JSONObject object) throws JSONException {
		final int id = JsonInput.getInt(object, "id");
		final String name = JsonInput.getStringNotNull(object, "name");
		return new Tracker(id, name);
	}
690291
function track(property, thisArg){
    if(!(property in trackedProperties)){
      trackedProperties[property] = true;
      values[property] = model[property];
      Object.defineProperty(model, property, {
        get: function () { return values[property]; },
        set: function(newValue) {
          var oldValue = values[property];
          values[property] = newValue;
          getListeners(property).forEach(function(callback){
            callback.call(thisArg, newValue, oldValue);
          });
        }
      });
    }
  }
989738
public void trackPageView(String argPageURL, String argPageTitle, String argHostName) {
        trackPageViewFromReferrer(argPageURL, argPageTitle, argHostName, "http://www.dmurph.com", "/");
    }
352213
function(object){
    var target = this.value();
    if(!object || !target || !target.isData || !object.isData){ return void 0; }
    target._cid || (target._cid = target.cid);
    object._cid || (object._cid = object.cid);
    target.cid = object.cid;
    this.tracking = object;
  }
233306
def track(cls, obj, ptr):
        
        cls._objects.add(cls(obj, ptr))