Ejemplo n.º 1
0
 @Nullable
 private String getOldPlatformToolsFolderPath() {
   String platformLocation;
   if (myWrapee.isPlatform()) {
     platformLocation = myWrapee.getLocation();
   } else {
     IAndroidTarget parent = myWrapee.getParent();
     platformLocation = parent != null ? parent.getLocation() : null;
   }
   if (platformLocation == null) {
     return null;
   }
   return platformLocation + SdkConstants.FD_TOOLS + File.separator;
 }
Ejemplo n.º 2
0
 @Nullable
 public IAndroidTarget findTargetByApiLevel(@NotNull String apiLevel) {
   IAndroidTarget candidate = null;
   for (IAndroidTarget target : getTargets()) {
     if (AndroidSdkUtils.targetHasId(target, apiLevel)) {
       if (target.isPlatform()) {
         return target;
       } else if (candidate == null) {
         candidate = target;
       }
     }
   }
   return candidate;
 }
Ejemplo n.º 3
0
 @Override
 public boolean isPlatform() {
   return myWrapee.isPlatform();
 }