%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /proc/985914/root/data/old/home/stash/stash/atlassian-stash/static/model/
Upload File :
Create Path :
Current File : //proc/985914/root/data/old/home/stash/stash/atlassian-stash/static/model/path-min.js

define("model/path",["backbone-brace"],function(A){function D(E){return E.length?E[E.length-1]:null}function C(E){E=E||"";var F=E.lastIndexOf(".");return F>0?E.substring(F+1):""}var B=A.Model.extend({_separator:"/",namedAttributes:{components:["string"],extension:"string",name:"string"},constructor:function(F){var G=[];if(F instanceof Array){G=F.slice(0)}else{if(F){if(F.split){G=F.length?F.split(this._separator):[];if(G.length){if(!G[G.length-1]){G.pop()}if(!G[0]){G.shift()}}}else{if(F.components){G=F.components.slice(0)}else{if(F.getComponents){G=F.getComponents().slice(0)}}}}}var E=D(G);var H=C(E);Backbone.Model.call(this,{});this.setComponents(G);this.setName(E);this.setExtension(H)},getParent:function(){return this.getComponents().length?new B(this.getComponents().slice(0,this.getComponents().length-1)):null},isSameDirectory:function(F){if(this.getComponents().length!==F.getComponents().length){return false}var E=this.getComponents().length-2;while(E>=0&&this.getComponents()[E]===F.getComponents()[E]){E--}return E<0},toString:function(){return this.getComponents().join(this._separator)}},{fromParentAndName:function(E,F){return new B(E.getComponents().concat(F))}});return B});

Zerion Mini Shell 1.0