Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(73)

Side by Side Diff: dart/editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/pub/PubspecModel.java

Issue 411603002: Version 1.5.8 (Closed) Base URL: http://dart.googlecode.com/svn/branches/1.5/
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012, the Dart project authors. 2 * Copyright (c) 2012, the Dart project authors.
3 * 3 *
4 * Licensed under the Eclipse Public License v1.0 (the "License"); you may not u se this file except 4 * Licensed under the Eclipse Public License v1.0 (the "License"); you may not u se this file except
5 * in compliance with the License. You may obtain a copy of the License at 5 * in compliance with the License. You may obtain a copy of the License at
6 * 6 *
7 * http://www.eclipse.org/legal/epl-v10.html 7 * http://www.eclipse.org/legal/epl-v10.html
8 * 8 *
9 * Unless required by applicable law or agreed to in writing, software distribut ed under the License 9 * Unless required by applicable law or agreed to in writing, software distribut ed under the License
10 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY K IND, either express 10 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY K IND, either express
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after
390 } else { 390 } else {
391 sdkVersion = EMPTY_STRING; 391 sdkVersion = EMPTY_STRING;
392 } 392 }
393 393
394 description = (String) ((pubspecMap.get(PubspecConstants.DESCRIPTION) != n ull) 394 description = (String) ((pubspecMap.get(PubspecConstants.DESCRIPTION) != n ull)
395 ? pubspecMap.get(PubspecConstants.DESCRIPTION) : EMPTY_STRING); 395 ? pubspecMap.get(PubspecConstants.DESCRIPTION) : EMPTY_STRING);
396 homepage = (String) ((pubspecMap.get(PubspecConstants.HOMEPAGE) != null) 396 homepage = (String) ((pubspecMap.get(PubspecConstants.HOMEPAGE) != null)
397 ? pubspecMap.get(PubspecConstants.HOMEPAGE) : EMPTY_STRING); 397 ? pubspecMap.get(PubspecConstants.HOMEPAGE) : EMPTY_STRING);
398 documentation = (String) ((pubspecMap.get(PubspecConstants.DOCUMENTATION) != null) 398 documentation = (String) ((pubspecMap.get(PubspecConstants.DOCUMENTATION) != null)
399 ? pubspecMap.get(PubspecConstants.DOCUMENTATION) : EMPTY_STRING); 399 ? pubspecMap.get(PubspecConstants.DOCUMENTATION) : EMPTY_STRING);
400 transformers = (ArrayList<Object>) ((pubspecMap.get(PubspecConstants.TRANS FORMERS) != null) 400 Object object = ((pubspecMap.get(PubspecConstants.TRANSFORMERS) != null)
401 ? pubspecMap.get(PubspecConstants.TRANSFORMERS) : new ArrayList<Object >()); 401 ? pubspecMap.get(PubspecConstants.TRANSFORMERS) : new ArrayList<Object >());
402 if (object instanceof ArrayList<?>) {
403 transformers = (ArrayList<Object>) object;
404 }
402 add( 405 add(
403 processDependencies( 406 processDependencies(
404 (Map<String, Object>) pubspecMap.get(PubspecConstants.DEPENDENCIES ), 407 (Map<String, Object>) pubspecMap.get(PubspecConstants.DEPENDENCIES ),
405 false), 408 false),
406 IModelListener.REFRESH); 409 IModelListener.REFRESH);
407 add( 410 add(
408 processDependencies( 411 processDependencies(
409 (Map<String, Object>) pubspecMap.get(PubspecConstants.DEV_DEPENDEN CIES), 412 (Map<String, Object>) pubspecMap.get(PubspecConstants.DEV_DEPENDEN CIES),
410 true), 413 true),
411 IModelListener.REFRESH); 414 IModelListener.REFRESH);
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
524 yamlMap.put(PubspecConstants.DEV_DEPENDENCIES, new TreeMap<String, Objec t>( 527 yamlMap.put(PubspecConstants.DEV_DEPENDENCIES, new TreeMap<String, Objec t>(
525 devDependenciesMap)); 528 devDependenciesMap));
526 } 529 }
527 yamlMap.remove(PubspecConstants.TRANSFORMERS); 530 yamlMap.remove(PubspecConstants.TRANSFORMERS);
528 if (!transformers.isEmpty()) { 531 if (!transformers.isEmpty()) {
529 yamlMap.put(PubspecConstants.TRANSFORMERS, transformers); 532 yamlMap.put(PubspecConstants.TRANSFORMERS, transformers);
530 } 533 }
531 } 534 }
532 } 535 }
533 } 536 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698